[llvm] Reapply "[LLVM][TableGen] Parameterize NumToSkip in DecoderEmitter" (#136017) (PR #136019)

Sergei Barannikov via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 17 17:33:04 PDT 2025


s-barannikov wrote:

> I think this has something to do with these functions are not purely local (they are declared in the llvm namespace) so at link time the compiler may see 2 copies that are not identical and choose to merge them, leading to correctness issues. I think one difference between my regular setup and the expensive check build was clang vs gcc for building. Maybe clang and gcc handle these cases differently (clang does not merge and gcc merges them).

The explanation doesn't sound convincing to me, `static` functions should not be considered for merging regardless of the namespace they are declared in. Can you provide perhaps make a small reproducer?


https://github.com/llvm/llvm-project/pull/136019


More information about the llvm-commits mailing list