mmjjpp wrote:

The fixes for the review comments above have been pushed.

> I notice that SplitModule.cpp has some handling to avoid duplicated module 
> inline asm:
>
> https://github.com/llvm/llvm-project/blob/2cf68b2cc466710badbe560ad6081f71c72ed331/llvm/lib/Transforms/Utils/SplitModule.cpp#L294
>
> . Is something similar needed here?

Yes — this was indeed a missed case. `SplitModuleCG::splitModule()` now
calls `MPart->removeModuleInlineAsm()` for `I != 0`, keeping the module
inline asm only in partition 0 (matching llvm::SplitModule), so its
contents are no longer duplicated when the partition objects are linked
together. Added
`llvm/test/tools/llvm-split/SplitModuleCG/module-asm.ll` to verify it.

Noted. I'll avoid force-pushing this PR while the review is in
progress, so the changes since your last review stay visible as
incremental commits.



https://github.com/llvm/llvm-project/pull/198702
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to