Patchwork [testsuite,g++.dg] : Fix for windows targets dll(import/export)-MI1.C tests

login
register
mail settings
Submitter Kai Tietz
Date Jan. 4, 2011, 2:06 p.m.
Message ID <AANLkTikW=T=zYbw6YRuUmB4XRL6jQufrQPSO9UQ09VO5@mail.gmail.com>
Download mbox | patch
Permalink /patch/77474/
State New
Headers show

Comments

Kai Tietz - Jan. 4, 2011, 2:06 p.m.
Hello,

This patch fixes issues related about quoting in dllexport.C for
cygwin/mingw 32-bit. Additionally it enables dllexport-MI1 and
dllimport-MI1 test for 64-bit mingw, too.

ChangeLog testsuite/

        * g++.dg/ext/dllexport-MI1.C: Adjust test.
        * g++.dg/ext/dllimport-MI1.C: Likewise.

Tested for i686-pc-cygwin, i686-w64-mingw32, and x86_64-w64-mingw32.
Ok for apply?

Regards,
Kai
Kai Tietz - Jan. 7, 2011, 2:13 p.m.
gcc-patches-owner@gcc.gnu.org wrote on 04.01.2011 15:06:47:

> Hello,
> 
> This patch fixes issues related about quoting in dllexport.C for
> cygwin/mingw 32-bit. Additionally it enables dllexport-MI1 and
> dllimport-MI1 test for 64-bit mingw, too.
> 
> ChangeLog testsuite/
> 
>         * g++.dg/ext/dllexport-MI1.C: Adjust test.
>         * g++.dg/ext/dllimport-MI1.C: Likewise.
> 
> Tested for i686-pc-cygwin, i686-w64-mingw32, and x86_64-w64-mingw32.
> Ok for apply?
> 
> Regards,
> Kai
> [attachment "g++_dg_ext.txt" deleted by Kai Tietz/Onevision] 

Approved by Jason on IRC.
Applied at revision 168572.

Regards,
Kai

Patch

Index: dllimport-MI1.C
===================================================================
--- dllimport-MI1.C	(revision 168457)
+++ dllimport-MI1.C	(working copy)
@@ -1,4 +1,4 @@ 
-// { dg-do compile { target i?86-*-cygwin* i?86-*-mingw*} }
+// { dg-do compile { target i?86-*-cygwin* i?86-*-mingw* x86_64-*-mingw* } }
 //  Test handling of MI thunks in dllimported classes.
 
 // To build the dll and client app:
@@ -49,5 +49,5 @@ 
 
 // Scan for import of explicit copy ctor for D2, but no import
 // of compiler generated copy ctor for D1. 
-// { dg-final { scan-assembler  "__imp___ZN2D2C2ERKS_" } }
-// { dg-final { scan-assembler-not "__imp___ZN2D1C2ERKS_" } }
+// { dg-final { scan-assembler  "__imp\[_\]*__ZN2D2C2ERKS_" } }
+// { dg-final { scan-assembler-not "__imp\[_\]*__ZN2D1C2ERKS_" } }
Index: dllexport-MI1.C
===================================================================
--- dllexport-MI1.C	(revision 168457)
+++ dllexport-MI1.C	(working copy)
@@ -33,12 +33,12 @@ 
 
 // and MI thunks,
 
-// { dg-final { scan-assembler "-export:\[\\\\\"\]*_ZThn4_NK3MI12vfEv" } }
-// { dg-final { scan-assembler "-export:\[\\\\\"\]*_ZTv0_n12_NK2D12vfEv" } }
+// { dg-final { scan-assembler "-export:\[\\\\\"\]*_ZThn._NK3MI12vfEv" } }
+// { dg-final { scan-assembler "-export:\[\\\\\"\]*_ZTv0_n.._NK2D12vfEv" } }
 
 // and a vtable data variable.
 
-// { dg-final { scan-assembler "-export:\[\\\\\"\]*_ZTV2D1\[\\\"\]*,data" } }
+// { dg-final { scan-assembler "-export:\[\\\\\"\]*_ZTV2D1\[\\\\\"\]*,data" } }
 
 // an explicit copy ctor
 // { dg-final { scan-assembler "-export:\[\\\\\"\]*_ZN2D2C2ERKS_" } }