Bug ID: 36297
           Summary: [ELF] - LLD can produce excessive undefined symbols
                    with specific linker script.
           Product: lld
           Version: unspecified
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: ELF

Imagine following script:

SECTIONS { .bar (a+b) : { *(.stub) } };

And assume that there is no .stub section in object.
"a+b" here is address expression.
We add all symbols referenced by script as undefined
early. ".bar" becomes empty section and removed from output.

a and b though present as undefined in symtab and no error
is produced.

bfd produce error:
test.script:4: non constant or forward reference address expression for section

gold too:
ld: error: undefined symbol 'a' referenced in expression
ld: error: undefined symbol 'a' referenced in expression

You are receiving this mail because:
You are on the CC list for the bug.
llvm-bugs mailing list

Reply via email to