This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] riscv: remove DL_RO_DYN_SECTION
- From: Palmer Dabbelt <palmer at sifive dot com>
- To: david dot abdurachmanov at gmail dot com
- Cc: libc-alpha at sourceware dot org, david dot abdurachmanov at gmail dot com, Jim Wilson <jimw at sifive dot com>, dj at delorie dot com
- Date: Thu, 25 Apr 2019 10:54:32 -0700 (PDT)
- Subject: Re: [PATCH] riscv: remove DL_RO_DYN_SECTION
On Tue, 09 Apr 2019 04:25:29 PDT (-0700), david.abdurachmanov@gmail.com wrote:
While working on enabling D front-end (GDC) in GCC we noticed that druntime
was segfaulting if it is linked dynamically. This was tracked to
DL_RO_DYN_SECTION.
DL_RO_DYN_SECTION lines seem to be copied from MIPS file (which is the only
user of it), but the comment doesn't apply to RISC-V. There is no such
requirement in RISC-V ABI.
* sysdeps/riscv/ldsodefs.h: Remove DL_RO_DYN_SECTION as it is not
required by RISC-V ABI.
Signed-off-by: David Abdurachmanov <david.abdurachmanov@gmail.com>
Cc: jimw@sifive.com
Cc: palmer@sifive.com
Cc: dj@delorie.com
---
sysdeps/riscv/ldsodefs.h | 4 ----
1 file changed, 4 deletions(-)
diff --git a/sysdeps/riscv/ldsodefs.h b/sysdeps/riscv/ldsodefs.h
index f46cf4158e..5ec607e867 100644
--- a/sysdeps/riscv/ldsodefs.h
+++ b/sysdeps/riscv/ldsodefs.h
@@ -38,10 +38,6 @@ struct La_riscv_retval;
struct La_riscv_retval *, \
const char *);
-/* The RISC-V ABI specifies that the dynamic section has to be read-only. */
-
-#define DL_RO_DYN_SECTION 1
-
#include_next <ldsodefs.h>
#endif
Thanks. I went ahead and pushed it without a test case so we don't lose the
fix. I also opened a Bugzilla:
https://sourceware.org/bugzilla/show_bug.cgi?id=24484