llvm-project
194ce879 - [Clang][HIP] Skip internalization for non-LTO device links (#225859)

Commit
6 days ago
[Clang][HIP] Skip internalization for non-LTO device links (#225859) A non-LTO HIP device link can combine native relocatable objects with bitcode libraries. This can happen with both RDC and non-RDC compilation. LLD must resolve undefined symbols in the native objects with definitions from the bitcode. The LTO step processing the bitcode cannot see references from native objects. Internalizing non-kernel functions can therefore hide definitions that those objects need. Do not enable AMDGPU internalization for these mixed non-LTO links. LTO mode does not have this problem. It links the bitcode modules before internalization, so the references are visible when symbols are resolved. Keep internalization for LTO links and when compiling non-RDC main modules.
Author
Parents
Loading