diff mbox

HPPA constructor merge patch, PR middle-end/45388

Message ID 20101214095919.GB10352@kam.mff.cuni.cz
State New
Headers show

Commit Message

Jan Hubicka Dec. 14, 2010, 9:59 a.m. UTC
> This caused:
> 
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46933

Hi,
the problem is that gcc.dg/other/first-global testcase tests that the recognizable
name of global constructor contans name of the first global in the module.  This
is bit fragile test given the fact that ELF system don't need recognizable name here.
But since we now just add the sub_ string I guess the testcase can be updated as follows.
(the name does not change on systems that need collect2 to produce __main.  Thus the OR
sequence)

Seems to make sense?

Comments

Richard Henderson Dec. 14, 2010, 10:28 a.m. UTC | #1
On 12/14/2010 01:59 AM, Jan Hubicka wrote:
> --- testsuite/g++.dg/other/first-global.C	(revision 167752)
> +++ testsuite/g++.dg/other/first-global.C	(working copy)
> @@ -1,6 +1,6 @@
>  /* { dg-do compile } */
>  /* { dg-add-options bind_pic_locally } */
> -/* { dg-final { scan-assembler "_GLOBAL__I(_|_65535_0_)foobar" } } */
> +/* { dg-final { scan-assembler "_GLOBAL__(I|sub_I)(_|_65535_0_)foobar" } } */

Ok.


r~
diff mbox

Patch

Index: testsuite/g++.dg/other/first-global.C
===================================================================
--- testsuite/g++.dg/other/first-global.C	(revision 167752)
+++ testsuite/g++.dg/other/first-global.C	(working copy)
@@ -1,6 +1,6 @@ 
 /* { dg-do compile } */
 /* { dg-add-options bind_pic_locally } */
-/* { dg-final { scan-assembler "_GLOBAL__I(_|_65535_0_)foobar" } } */
+/* { dg-final { scan-assembler "_GLOBAL__(I|sub_I)(_|_65535_0_)foobar" } } */
 
 struct foo { foo (); };
 foo foobar;