This is the mail archive of the binutils@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]

gold patch committed: Fix i386 testsuite failure


This patch fixes a failure in gold built for 32-bit x86.  The test only
works if Ordering::operator() is a different size in the compiled
odr_violation1.cc and odr_violation2.cc.  The existing code was too
similar, and the size wound up being the same in 32-bit mode.  This
patch makes the size different.  The actual contents of the function are
irrelevant for this test.  Committed to mainline.

Ian


2011-07-08  Ian Lance Taylor  <iant@google.com>

	* testsuite/odr_violation2.cc (Ordering::operator()): Make
	expression more complex.


Index: testsuite/odr_violation2.cc
===================================================================
RCS file: /cvs/src/src/gold/testsuite/odr_violation2.cc,v
retrieving revision 1.4
diff -u -r1.4 odr_violation2.cc
--- testsuite/odr_violation2.cc	11 Mar 2011 21:42:12 -0000	1.4
+++ testsuite/odr_violation2.cc	9 Jul 2011 05:09:21 -0000
@@ -12,7 +12,7 @@
 bool Ordering::operator()(int a, int b) {
   // Optimization makes this operator() a different size than the one
   // in odr_violation1.cc.
-  return a + 1 > b + 1;
+  return a + 12345 > b / 67;
 }
 
 void SortDescending(int array[], int size) {

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