RE: [PATCH 12/13] Adjust relevant test cases wrt -ftrack-macro-expansion=[0|2]

2012-05-02 Thread Greta Yorsh
There are a couple more test that need adjusting:
gcc.dg/fixed-point/operator-bitwise.c
gcc.dg/fixed-point/composite-type.c

These tests fail on arm-none-eabi. 
Below is a patch that fixes them.

Thanks,
Greta

gcc/testsuite

2012-05-02  Greta Yorsh  greta.yo...@arm.com

* gcc.dg/fixed-point/composite-type.c (dg-options): Add
option -ftrack-macro-expansion=0.
* gcc.dg/fixed-point/operator-bitwise.c (dg-options): Add
option -ftrack-macro-expansion=0.

diff --git a/gcc/testsuite/gcc.dg/fixed-point/composite-type.c
b/gcc/testsuite/gcc.dg/fixed-point/composite-type.c
index 5ae1198..026bdaf 100644
--- a/gcc/testsuite/gcc.dg/fixed-point/composite-type.c
+++ b/gcc/testsuite/gcc.dg/fixed-point/composite-type.c
@@ -1,5 +1,5 @@
 /* { dg-do compile } */
-/* { dg-options -std=gnu99 -O -Wall -Wno-unused } */
+/* { dg-options -std=gnu99 -O -Wall -Wno-unused -ftrack-macro-expansion=0
} */
 
 /* C99 6.2.7: Compatible type and composite type.  */
 
diff --git a/gcc/testsuite/gcc.dg/fixed-point/operator-bitwise.c
b/gcc/testsuite/gcc.dg/fixed-point/operator-bitwise.c
index 31aecf5..6ba817d 100644
--- a/gcc/testsuite/gcc.dg/fixed-point/operator-bitwise.c
+++ b/gcc/testsuite/gcc.dg/fixed-point/operator-bitwise.c
@@ -1,5 +1,5 @@
 /* { dg-do compile } */
-/* { dg-options -std=gnu99 } */
+/* { dg-options -std=gnu99 -ftrack-macro-expansion=0 } */
 
 /* C99 6.5.10: Bitwise AND operator.
C99 6.5.11: Bitwise exclusive OR operator.


 -Original Message-
 From: Mike Stump [mailto:mikest...@comcast.net]
 Sent: 30 April 2012 17:09
 To: Dodji Seketeli
 Cc: Gabriel Dos Reis; GCC Patches; Tom Tromey; Jason Merrill; Paolo
 Carlini; Benjamin De Kosnik
 Subject: Re: [PATCH 12/13] Adjust relevant test cases wrt -ftrack-
 macro-expansion=[0|2]
 
 On Apr 29, 2012, at 10:38 AM, Dodji Seketeli wrote:
  While bootstrapping the tree again, it appeared that an output
  regression of the objc test objc.dg/foreach-7.m flew below my radar.
 
  This looks fairly obvious to me, but I am CC-ing Mike Stump, just in
  case.
 
 That's fine.






Re: [PATCH 12/13] Adjust relevant test cases wrt -ftrack-macro-expansion=[0|2]

2012-04-30 Thread Dodji Seketeli
Dodji Seketeli do...@redhat.com writes:

 Gabriel Dos Reis g...@integrable-solutions.net writes:

 OK.

 Thank you.

 While bootstrapping the tree again, it appeared that an output
 regression of the objc test objc.dg/foreach-7.m flew below my radar.

 It's one of those typical cases where the first location pointed to by
 the diagnostics points into the definition of a macro, instead of
 pointing to its expansion point.  I have just forced that unique test to
 run without -ftrack-macro-expansion.

 This looks fairly obvious to me, but I am CC-ing Mike Stump, just in
 case.

 I have updated this patch to include the adjustment for
 objc.dg/foreach-7.m.  All the other parts remained unchanged.

 Tested on x86_64-unknown-linux-gnu against trunk, bootstrap still
 underway.

FWIW, this passed bootstrap fine.

-- 
Dodji


Re: [PATCH 12/13] Adjust relevant test cases wrt -ftrack-macro-expansion=[0|2]

2012-04-30 Thread Gabriel Dos Reis
It is still OK :-)

On Mon, Apr 30, 2012 at 1:22 AM, Dodji Seketeli do...@redhat.com wrote:
 Dodji Seketeli do...@redhat.com writes:

 Gabriel Dos Reis g...@integrable-solutions.net writes:

 OK.

 Thank you.

 While bootstrapping the tree again, it appeared that an output
 regression of the objc test objc.dg/foreach-7.m flew below my radar.

 It's one of those typical cases where the first location pointed to by
 the diagnostics points into the definition of a macro, instead of
 pointing to its expansion point.  I have just forced that unique test to
 run without -ftrack-macro-expansion.

 This looks fairly obvious to me, but I am CC-ing Mike Stump, just in
 case.

 I have updated this patch to include the adjustment for
 objc.dg/foreach-7.m.  All the other parts remained unchanged.

 Tested on x86_64-unknown-linux-gnu against trunk, bootstrap still
 underway.

 FWIW, this passed bootstrap fine.

 --
                Dodji


Re: [PATCH 12/13] Adjust relevant test cases wrt -ftrack-macro-expansion=[0|2]

2012-04-30 Thread Mike Stump
On Apr 29, 2012, at 10:38 AM, Dodji Seketeli wrote:
 While bootstrapping the tree again, it appeared that an output
 regression of the objc test objc.dg/foreach-7.m flew below my radar.

 This looks fairly obvious to me, but I am CC-ing Mike Stump, just in
 case.

That's fine.


Re: [PATCH 12/13] Adjust relevant test cases wrt -ftrack-macro-expansion=[0|2]

2012-04-29 Thread Dodji Seketeli
Gabriel Dos Reis g...@integrable-solutions.net writes:

 OK.

Thank you.

While bootstrapping the tree again, it appeared that an output
regression of the objc test objc.dg/foreach-7.m flew below my radar.

It's one of those typical cases where the first location pointed to by
the diagnostics points into the definition of a macro, instead of
pointing to its expansion point.  I have just forced that unique test to
run without -ftrack-macro-expansion.

This looks fairly obvious to me, but I am CC-ing Mike Stump, just in
case.

I have updated this patch to include the adjustment for
objc.dg/foreach-7.m.  All the other parts remained unchanged.

Tested on x86_64-unknown-linux-gnu against trunk, bootstrap still
underway.

gcc/testsuite/

* objc.dg/foreach-7.m: Force the test case to run without
-ftrack-macro-expansion.
* c-c++-common/tm/attrib-1.c: Likewise.
* c-c++-common/warn-ommitted-condop.c: Likewise.
* gcc.dg/assign-warn-1.c: Likewise.
* gcc.dg/assign-warn-2.c: Likewise.
* gcc.dg/attr-alloc_size.c: Likewise.
* gcc.dg/builtin-stringop-chk-1.c: Likewise.
* gcc.dg/builtin-stringop-chk-2.c: Likewise.
* gcc.dg/builtin-strncat-chk-1.c: Likewise.
* gcc.dg/c90-const-expr-9.c: Likewise.
* gcc.dg/c99-const-expr-9.c: Likewise.
* gcc.dg/cpp/direct2.c: Likewise.  Adjust.
* gcc.dg/cpp/direct2s.c: Likewise.
* gcc/testsuite/gcc.dg/cpp/pr28709.c: Likewise.
* gcc.dg/cpp/pragma-diagnostic-1.c: Likewise.
* gcc.dg/dfp/composite-type.c: Likewise.
* gcc.dg/uninit-6-O0.c: Adjust the test case and force it to run
with -ftrack-macro-expansion
* g++.dg/cpp0x/constexpr-ex3.C: Likewise.
* g++.dg/cpp0x/constexpr-overflow.C: Likewise.
* g++.dg/ext/cleanup-1.C: Likewise.
* g++.dg/ext/gnu-inline-global-reject.C: Likewise.
* g++.dg/template/sfinae10.C: Likewise.
* g++.dg/tm/wrap-2.C: Likewise.
* g++.dg/warn/Wconversion-real-integer.C: Likewise.
* g++.dg/warn/Wsign-conversion.C: Likewise.
* g++.dg/warn/multiple-overflow-warn-1.C: Likewise.
* g++.old-deja/g++.mike/p10769b.C: Likewise.
* g++.dg/warn/Wdouble-promotion.C: Adjust the test case and force
it to run with -ftrack-macro-expansion.
* libstdc++-v3/scripts/testsuite_flags.in: By default, run the
test cases without -ftrack-macro-expansion.
---
 gcc/testsuite/c-c++-common/tm/attrib-1.c   |2 +-
 gcc/testsuite/c-c++-common/warn-ommitted-condop.c  |2 +-
 gcc/testsuite/g++.dg/cpp0x/constexpr-ex3.C |2 +-
 gcc/testsuite/g++.dg/cpp0x/constexpr-overflow.C|2 +-
 gcc/testsuite/g++.dg/ext/cleanup-1.C   |2 +-
 .../g++.dg/ext/gnu-inline-global-reject.C  |2 +-
 gcc/testsuite/g++.dg/template/sfinae10.C   |2 +-
 gcc/testsuite/g++.dg/tm/wrap-2.C   |2 +-
 .../g++.dg/warn/Wconversion-real-integer.C |2 +-
 gcc/testsuite/g++.dg/warn/Wdouble-promotion.C  |6 +++---
 gcc/testsuite/g++.dg/warn/Wsign-conversion.C   |2 +-
 .../g++.dg/warn/multiple-overflow-warn-1.C |2 +-
 gcc/testsuite/g++.old-deja/g++.mike/p10769b.C  |2 +-
 gcc/testsuite/gcc.dg/assign-warn-1.c   |2 +-
 gcc/testsuite/gcc.dg/assign-warn-2.c   |2 +-
 gcc/testsuite/gcc.dg/attr-alloc_size.c |2 +-
 gcc/testsuite/gcc.dg/builtin-stringop-chk-1.c  |2 +-
 gcc/testsuite/gcc.dg/builtin-stringop-chk-2.c  |2 +-
 gcc/testsuite/gcc.dg/builtin-strncat-chk-1.c   |2 +-
 gcc/testsuite/gcc.dg/c90-const-expr-9.c|2 +-
 gcc/testsuite/gcc.dg/c99-const-expr-9.c|2 +-
 gcc/testsuite/gcc.dg/cpp/direct2.c |   12 +++-
 gcc/testsuite/gcc.dg/cpp/direct2s.c|2 +-
 gcc/testsuite/gcc.dg/cpp/pr28709.c |8 +---
 gcc/testsuite/gcc.dg/cpp/pragma-diagnostic-1.c |2 +-
 gcc/testsuite/gcc.dg/dfp/composite-type.c  |2 +-
 gcc/testsuite/gcc.dg/uninit-6-O0.c |6 +++---
 gcc/testsuite/objc.dg/foreach-7.m  |9 ++---
 libstdc++-v3/scripts/testsuite_flags.in|2 +-
 29 files changed, 48 insertions(+), 41 deletions(-)

diff --git a/gcc/testsuite/c-c++-common/tm/attrib-1.c 
b/gcc/testsuite/c-c++-common/tm/attrib-1.c
index 536aeb3..534fa0e 100644
--- a/gcc/testsuite/c-c++-common/tm/attrib-1.c
+++ b/gcc/testsuite/c-c++-common/tm/attrib-1.c
@@ -1,5 +1,5 @@
 /* { dg-do compile } */
-/* { dg-options -fgnu-tm } */
+/* { dg-options -fgnu-tm -ftrack-macro-expansion=0 } */
 
 #define TC __attribute__((transaction_callable))
 #define TU __attribute__((transaction_unsafe))
diff --git a/gcc/testsuite/c-c++-common/warn-ommitted-condop.c 
b/gcc/testsuite/c-c++-common/warn-ommitted-condop.c
index de92b8f..0726f04 100644
--- 

[PATCH 12/13] Adjust relevant test cases wrt -ftrack-macro-expansion=[0|2]

2012-04-25 Thread Dodji Seketeli
Even after all the patches I have already submitted for this
-ftrack-macro-expansion business, some test cases where errors happens
on tokens that are defined in macros see their output change in an
incompatible way, when you run them with or without
-ftrack-macro-expansion.

I think this is expected, because the (spelling) locus inside the
definition of the macro pointed to with -ftrack-macro-expansion is
different from the locus of the expansion point of the macro pointed
to without -ftrack-macro-expansion.

In those cases this patch either adjusts the test case and forces it
be run either with -ftrack-macro-expansion, or it just forces it to be
run without -ftrack-macro-expansion.

There are so many libstdc++ tests that were failing because of that
benign issue that I preferred to just run them with
-ftrack-macro-expansion diabled, after inspecting each of them to be
sure there was nothing more serious underneath.  I believe we can latter
turn on -ftrack-macro-expansion there on a case by case basis.

Boostrapped on x86_64-unknown-linux-gnu against trunk with and without
-ftrack-macro-expansion turned on.

gcc/testsuite/

* c-c++-common/tm/attrib-1.c: Force the test case to run without
-ftrack-macro-expansion.
* c-c++-common/warn-ommitted-condop.c: Likewise.
* gcc.dg/assign-warn-1.c: Likewise.
* gcc.dg/assign-warn-2.c: Likewise.
* gcc.dg/attr-alloc_size.c: Likewise.
* gcc.dg/builtin-stringop-chk-1.c: Likewise.
* gcc.dg/builtin-stringop-chk-2.c: Likewise.
* gcc.dg/builtin-strncat-chk-1.c: Likewise.
* gcc.dg/c90-const-expr-9.c: Likewise.
* gcc.dg/c99-const-expr-9.c: Likewise.
* gcc.dg/cpp/direct2.c: Likewise.  Adjust.
* gcc.dg/cpp/direct2s.c: Likewise.
* gcc/testsuite/gcc.dg/cpp/pr28709.c: Likewise.
* gcc.dg/cpp/pragma-diagnostic-1.c: Likewise.
* gcc.dg/dfp/composite-type.c: Likewise.
* gcc.dg/uninit-6-O0.c: Adjust the test case and force it to run
with -ftrack-macro-expansion
* g++.dg/cpp0x/constexpr-ex3.C: Likewise.
* g++.dg/cpp0x/constexpr-overflow.C: Likewise.
* g++.dg/ext/cleanup-1.C: Likewise.
* g++.dg/ext/gnu-inline-global-reject.C: Likewise.
* g++.dg/template/sfinae10.C: Likewise.
* g++.dg/tm/wrap-2.C: Likewise.
* g++.dg/warn/Wconversion-real-integer.C: Likewise.
* g++.dg/warn/Wsign-conversion.C: Likewise.
* g++.dg/warn/multiple-overflow-warn-1.C: Likewise.
* g++.old-deja/g++.mike/p10769b.C: Likewise.
* g++.dg/warn/Wdouble-promotion.C: Adjust the test case and force
it to run with -ftrack-macro-expansion.
* libstdc++-v3/scripts/testsuite_flags.in: By default, run the
test cases without -ftrack-macro-expansion.
---
 gcc/testsuite/c-c++-common/tm/attrib-1.c   |2 +-
 gcc/testsuite/c-c++-common/warn-ommitted-condop.c  |2 +-
 gcc/testsuite/g++.dg/cpp0x/constexpr-ex3.C |2 +-
 gcc/testsuite/g++.dg/cpp0x/constexpr-overflow.C|2 +-
 gcc/testsuite/g++.dg/ext/cleanup-1.C   |2 +-
 .../g++.dg/ext/gnu-inline-global-reject.C  |2 +-
 gcc/testsuite/g++.dg/template/sfinae10.C   |2 +-
 gcc/testsuite/g++.dg/tm/wrap-2.C   |2 +-
 .../g++.dg/warn/Wconversion-real-integer.C |2 +-
 gcc/testsuite/g++.dg/warn/Wdouble-promotion.C  |6 +++---
 gcc/testsuite/g++.dg/warn/Wsign-conversion.C   |2 +-
 .../g++.dg/warn/multiple-overflow-warn-1.C |2 +-
 gcc/testsuite/g++.old-deja/g++.mike/p10769b.C  |2 +-
 gcc/testsuite/gcc.dg/assign-warn-1.c   |2 +-
 gcc/testsuite/gcc.dg/assign-warn-2.c   |2 +-
 gcc/testsuite/gcc.dg/attr-alloc_size.c |2 +-
 gcc/testsuite/gcc.dg/builtin-stringop-chk-1.c  |2 +-
 gcc/testsuite/gcc.dg/builtin-stringop-chk-2.c  |2 +-
 gcc/testsuite/gcc.dg/builtin-strncat-chk-1.c   |2 +-
 gcc/testsuite/gcc.dg/c90-const-expr-9.c|2 +-
 gcc/testsuite/gcc.dg/c99-const-expr-9.c|2 +-
 gcc/testsuite/gcc.dg/cpp/direct2.c |   12 +++-
 gcc/testsuite/gcc.dg/cpp/direct2s.c|2 +-
 gcc/testsuite/gcc.dg/cpp/pr28709.c |8 +---
 gcc/testsuite/gcc.dg/cpp/pragma-diagnostic-1.c |2 +-
 gcc/testsuite/gcc.dg/dfp/composite-type.c  |2 +-
 gcc/testsuite/gcc.dg/uninit-6-O0.c |6 +++---
 libstdc++-v3/scripts/testsuite_flags.in|2 +-
 28 files changed, 42 insertions(+), 38 deletions(-)

diff --git a/gcc/testsuite/c-c++-common/tm/attrib-1.c 
b/gcc/testsuite/c-c++-common/tm/attrib-1.c
index 536aeb3..534fa0e 100644
--- a/gcc/testsuite/c-c++-common/tm/attrib-1.c
+++ b/gcc/testsuite/c-c++-common/tm/attrib-1.c
@@ -1,5 +1,5 @@
 /* { dg-do compile } */
-/* { dg-options -fgnu-tm } */
+/* { dg-options -fgnu-tm -ftrack-macro-expansion=0 } */
 
 

Re: [PATCH 12/13] Adjust relevant test cases wrt -ftrack-macro-expansion=[0|2]

2012-04-25 Thread Gabriel Dos Reis
On Wed, Apr 25, 2012 at 9:16 AM, Dodji Seketeli do...@redhat.com wrote:
 Even after all the patches I have already submitted for this
 -ftrack-macro-expansion business, some test cases where errors happens
 on tokens that are defined in macros see their output change in an
 incompatible way, when you run them with or without
 -ftrack-macro-expansion.

 I think this is expected, because the (spelling) locus inside the
 definition of the macro pointed to with -ftrack-macro-expansion is
 different from the locus of the expansion point of the macro pointed
 to without -ftrack-macro-expansion.

 In those cases this patch either adjusts the test case and forces it
 be run either with -ftrack-macro-expansion, or it just forces it to be
 run without -ftrack-macro-expansion.

 There are so many libstdc++ tests that were failing because of that
 benign issue that I preferred to just run them with
 -ftrack-macro-expansion diabled, after inspecting each of them to be
 sure there was nothing more serious underneath.  I believe we can latter
 turn on -ftrack-macro-expansion there on a case by case basis.

 Boostrapped on x86_64-unknown-linux-gnu against trunk with and without
 -ftrack-macro-expansion turned on.

OK.

-- Gaby


Re: [PATCH 12/13] Adjust relevant test cases wrt -ftrack-macro-expansion=[0|2]

2012-04-25 Thread Benjamin Kosnik

Hey hey! Looking good Dodji. Can't wait to use this stuff.

 There are so many libstdc++ tests that were failing because of that
 benign issue that I preferred to just run them with
 -ftrack-macro-expansion diabled, after inspecting each of them to be
 sure there was nothing more serious underneath.  I believe we can
 latter turn on -ftrack-macro-expansion there on a case by case basis.

Seems perfectly reasonable. I volunteer to look at the
libstdc++testsuite  changes once your patches are in checked in to
trunk. 

-benjamin