bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug ld/26378] [2.35 regression] incorrect WAX section flags in linker o


From: hjl.tools at gmail dot com
Subject: [Bug ld/26378] [2.35 regression] incorrect WAX section flags in linker output
Date: Wed, 12 Aug 2020 17:33:00 +0000

https://sourceware.org/bugzilla/show_bug.cgi?id=26378

--- Comment #2 from H.J. Lu <hjl.tools at gmail dot com> ---
.plt and text.* sections are special sections:

static const struct bfd_elf_special_section special_sections_p[] =
{
  { STRING_COMMA_LEN (".preinit_array"), -2, SHT_PREINIT_ARRAY, SHF_ALLOC +
SHF_WRITE },
  { STRING_COMMA_LEN (".plt"),            0, SHT_PROGBITS,      SHF_ALLOC +
SHF_EXECINSTR },
  { NULL,                   0,            0, 0,                 0 }
};

static const struct bfd_elf_special_section special_sections_t[] =
{
  { STRING_COMMA_LEN (".text"),  -2, SHT_PROGBITS, SHF_ALLOC + SHF_EXECINSTR },
  { STRING_COMMA_LEN (".tbss"),  -2, SHT_NOBITS,   SHF_ALLOC + SHF_WRITE +
SHF_TLS },
  { STRING_COMMA_LEN (".tdata"), -2, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE +
SHF_TLS },
  { NULL,                     0,  0, 0,            0 }
};

They have the SHF_EXECINSTR bit set.  Maybe we should also check if the type
field matches.

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


reply via email to

[Prev in Thread] Current Thread [Next in Thread]