This is the mail archive of the binutils-cvs@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] Work around gcc10 FAIL: S-records with constructors


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=a13ba30840ba7a8450dcb4edd356de61fcb89130

commit a13ba30840ba7a8450dcb4edd356de61fcb89130
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Sep 21 18:13:52 2019 +0930

    Work around gcc10 FAIL: S-records with constructors
    
    gcc10 on x86_64 and powerpc64le recognises that the loop in
    Foo::operator= can be turned into a call to memmove, which then
    results in an undefined symbol when linking.  Avoid that by making the
    loop smaller.
    
    	* testsuite/ld-srec/sr3.cc (FOO_MSG_LEN): Set to 4.

Diff:
---
 ld/ChangeLog                | 4 ++++
 ld/testsuite/ld-srec/sr3.cc | 2 +-
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/ld/ChangeLog b/ld/ChangeLog
index 57d4df7..eb7981e 100644
--- a/ld/ChangeLog
+++ b/ld/ChangeLog
@@ -1,3 +1,7 @@
+2019-09-22  Alan Modra  <amodra@gmail.com>
+
+	* testsuite/ld-srec/sr3.cc (FOO_MSG_LEN): Set to 4.
+
 2019-09-20  Nelson Chu <nelson.chu@sifive.com>
 
 	* testsuite/ld-riscv-elf/weakref32.s: Add relaxable undef weak code.
diff --git a/ld/testsuite/ld-srec/sr3.cc b/ld/testsuite/ld-srec/sr3.cc
index 0b5fa7e..29f8019 100644
--- a/ld/testsuite/ld-srec/sr3.cc
+++ b/ld/testsuite/ld-srec/sr3.cc
@@ -1,6 +1,6 @@
 // This file is compiled and linked into the S-record format.
 
-#define FOO_MSG_LEN 80
+#define FOO_MSG_LEN 4
 
 class Foo {
     static int foos;


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]