Moshtaghi, Alireza via llvm-dev
2020-May-28 20:20 UTC
[llvm-dev] LLD : __start_ and __end_ symbols for orphan sections
lld does not seem to create the __start and __end symbols for orphan sections. I would like to keep my linker script as generic as possible so how can I tell lld to create these symbols without having to add them in the linker script? Thanks A -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20200528/978ccd1a/attachment.html>
Fangrui Song via llvm-dev
2020-May-29 06:30 UTC
[llvm-dev] LLD : __start_ and __end_ symbols for orphan sections
On 2020-05-28, Moshtaghi, Alireza via llvm-dev wrote:>lld does not seem to create the __start and __end symbols for orphan sections. >I would like to keep my linker script as generic as possible so how can I tell lld to create these symbols without having to add them in the linker script? > >Thanks >AIt works for me. SECTIONS { data : { *(data) } } .section data,"aw" .quad __start_orphan .quad __stop_orphan .section orphan,"aw" .quad __start_data .quad __stop_data Can you give an example __start_ or __end_ symbols are not defined for orphan sections?
Moshtaghi, Alireza via llvm-dev
2020-Jun-02 07:00 UTC
[llvm-dev] LLD : __start_ and __end_ symbols for orphan sections
You are right it creates them but sets the protected flag (STV_PROTECTED) which seems to be the cause of my problem. How can I tell it to set the flag as STV_DEFAULT? Thanks A On 5/28/20, 11:30 PM, "Fangrui Song" <maskray at google.com> wrote: NetApp Security WARNING: This is an external email. Do not click links or open attachments unless you recognize the sender and know the content is safe. On 2020-05-28, Moshtaghi, Alireza via llvm-dev wrote: >lld does not seem to create the __start and __end symbols for orphan sections. >I would like to keep my linker script as generic as possible so how can I tell lld to create these symbols without having to add them in the linker script? > >Thanks >A It works for me. SECTIONS { data : { *(data) } } .section data,"aw" .quad __start_orphan .quad __stop_orphan .section orphan,"aw" .quad __start_data .quad __stop_data Can you give an example __start_ or __end_ symbols are not defined for orphan sections?
Reasonably Related Threads
- LLD : __start_ and __end_ symbols for orphan sections
- LLD : __start_ and __end_ symbols for orphan sections
- RFC: A new ABI for virtual calls, and a change to the virtual call representation in the IR
- RFC: A new ABI for virtual calls, and a change to the virtual call representation in the IR
- RFC: A new ABI for virtual calls, and a change to the virtual call representation in the IR