[Patch/testsuite]: Adjust g++.dg/torture/stackalign/unwind-*.C testcases for __USER_LABEL_PREFIX__

H.J. Lu hjl.tools@gmail.com
Mon Jan 26 20:54:00 GMT 2009

On Thu, Oct 2, 2008 at 10:21 AM, Janis Johnson <janis187@us.ibm.com> wrote:
> On Thu, 2008-10-02 at 16:24 +1300, Danny Smith wrote:
>> The unwind[1-6].C testcases in g++.dg/torture/stackalign fail on
>> mingw32 and cygwin because the inline asm statements refer to symbols
>> without the __USER_LABEL_PREFIX__, ("_" for these targets). This
>> causes undefined references .eg:
>> c:\tmp/cccCuiyY.o:unwind-1.C:(.text+0xa3): undefined reference to `g_ebp_save'
>> c:\tmp/cccCuiyY.o:unwind-1.C:(.text+0xa9): undefined reference to `g_esp_save'
>> c:\tmp/cccCuiyY.o:unwind-1.C:(.text+0xc3): undefined reference to `g_edi'
>> c:\tmp/cccCuiyY.o:unwind-1.C:(.text+0xc9): undefined reference to `g_esi'
>> c:\tmp/cccCuiyY.o:unwind-1.C:(.text+0xcf): undefined reference to `g_ebx'
>> c:\tmp/cccCuiyY.o:unwind-1.C:(.text+0xd5): undefined reference to `g_ebp'
>> c:\tmp/cccCuiyY.o:unwind-1.C:(.text+0xdb): undefined reference to `g_esp'
>> This fixes by preprocessing the __USER_LABEL_PREFIX__ into the literal
>> asm names.
>> 2008-10-02  Danny Smith  <dannysmith@users.sourceforge.net>
>>       * g++.dg/torture/stackalign/test-unwind.h (ASMNAME): Define.
>>       Use instead of C name in asm statements.
> This is OK when it's been tested on a target where the test passed
> before the patch.

I ran it on Linux/ia32 and Linux/intel64. Results are OK:


I am checking it in.



More information about the Gcc-patches mailing list