[lld] [LLD] Add CLASS syntax to SECTIONS (PR #95323)
Daniel Thornburgh via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 24 17:03:25 PDT 2024
================
@@ -0,0 +1,377 @@
+# REQUIRES: x86
+
----------------
mysterymath wrote:
I had some code for this, but thinking about the test showed inconsistencies and in its behavior and undesirable semantics. I could see this coming up while transitioning a linker script from `--enable-non-contiguous-regions` to use classes, but otherwise it seems unlikely for this interaction to be very important.
Regarding the semantics, a uniquely-referenced class should just change the ordering of wildcard matching. That means that additional matches should produce possible spills for sections matched by earlier class definitions. It also means that class definitions should match sections already matched; these would become spills at later class references. This only required a slight tweak to matching.
https://github.com/llvm/llvm-project/pull/95323
More information about the llvm-commits
mailing list