请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。
器件型号:AM2434 工具/软件:
尊敬的 TI 团队:
我想我遇到了一个与相关的错误 链接时优化 (LTO) 在 tiarmlink
工具中使用 TI ARM CGT 3.2.2 LTS 。
设置:
- 构建系统: CMake 一方 Makefile 生成器
- 目标: Sitara AM2434 、使用 两个 R5 内核
- 工具链: TI ARM 编译器工具 3.2.2 LTS
- 我们构建多个静态库并链接两个可执行文件(每个内核一个)
- 通过
-flto
标志启用 LTO
问题:
- 生成内容 可靠地成功 运行时 保持并行性
-
--parallel
与 CMake(即)一起使用时make -jN
、构建 链接期间偶尔出现故障 - 带来问题 仅与一起出现
-flto
没有它,构建是稳定的 - 误差略有不同、这表明了一种可能 中的竞争条件
tiarmlink
错误片段:
示例 1:
[100%] Linking CXX executable CommunicationCore_lp_r5_1-0.out
../../master/ELFLNK/symbol.c:880:internal fatal error #10158: ("sprintf")
INTERNAL ERROR: ...\tiarmlnk executed an illegal instruction
This is caused by a defect in the TI Linker.
TI Customer Support may be able to suggest a workaround to avoid this.
...
示例 2:
[ 97%] Linking CXX executable CommunicationCore_lp_r5_1-0.out
[100%] Linking CXX executable ControllerCore_lp_r5_0-0.out
llvm-lto2: .../_Build/_Temp\100: Malformed block
tiarmclang: error: tiarmlnk command failed with exit code 1 (use -v to see invocation)
结语:
这似乎指向链接器 LTO 阶段的并发问题。 以前是否报告过此情况? 在较新版本的工具链中是否有已知的权变措施或修复?
此致、
Stefan