5 Commits

Author SHA1 Message Date
Jonas Hahnfeld
50ca8b3e87 [ORC] Drop Comdat when discarding IR symbol
According to the IR verifier, "Declaration[s] may not be in a Comdat!"

This is a re-commit of 76b3f0b4d5a0b8c54147c4c73a30892bbca76467 and
87d7838202267a011639fcbf97263556ccf091dc with updates to the test:
 * Force emission of the extra-module, to trigger the bug after D138264,
   by providing a second symbol @g, and making the comdat nodeduplicate.
   (Technically only one is needed, but two should be safer.)
 * Name the comdat $f to avoid failure on Windows:
   LLVM ERROR: Associative COMDAT symbol 'c' does not exist.
 * Mark the test as UNSUPPORTED on macOS, MachO doesn't support COMDATs.

Differential Revision: https://reviews.llvm.org/D142443
2023-02-05 10:53:36 +01:00
Jonas Hahnfeld
76d94d3eed Revert "[ORC] Drop Comdat when discarding IR symbol"
A number of AArch64 bots report errors in clang-repl, for example
https://lab.llvm.org/buildbot/#/builders/197/builds/3920

This reverts commit 87d7838202267a011639fcbf97263556ccf091dc.
2023-02-04 21:26:36 +01:00
Jonas Hahnfeld
87d7838202 [ORC] Drop Comdat when discarding IR symbol
According to the IR verifier, "Declaration[s] may not be in a Comdat!"

This is a re-commit of 76b3f0b4d5a0b8c54147c4c73a30892bbca76467 with
updates to the test:
 * Force emission of the extra-module, to trigger the bug after D138264,
   by providing a second symbol @g, and making the comdat nodeduplicate.
   (Technically only one is needed, but two should be safer.)
 * Name the comdat $f to avoid failure on Windows:
   LLVM ERROR: Associative COMDAT symbol 'c' does not exist.

Differential Revision: https://reviews.llvm.org/D142443
2023-02-03 11:16:19 +01:00
Jonas Hahnfeld
e5dd58e3a6 Revert "[ORC] Drop Comdat when discarding IR symbol"
Failure on Windows:
LLVM ERROR: Associative COMDAT symbol 'c' does not exist.

This reverts commit 76b3f0b4d5a0b8c54147c4c73a30892bbca76467 while
I investigate the problem and a solution that still triggers the
original problem.
2023-02-03 10:04:38 +01:00
Jonas Hahnfeld
76b3f0b4d5 [ORC] Drop Comdat when discarding IR symbol
According to the IR verifier, "Declaration[s] may not be in a Comdat!"

Differential Revision: https://reviews.llvm.org/D142443
2023-02-03 08:41:58 +01:00