Bug 49464 - [4.6/4.7 Regression] FAIL: g++.dg/ext/altivec-17.C (test for errors, line 15)
Summary: [4.6/4.7 Regression] FAIL: g++.dg/ext/altivec-17.C (test for errors, line 15)
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: testsuite (show other bugs)
Version: 4.7.0
: P4 normal
Target Milestone: 4.6.2
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-06-18 19:29 UTC by Dominique d'Humieres
Modified: 2011-09-07 12:24 UTC (History)
3 users (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed: 2011-06-20 11:00:17


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dominique d'Humieres 2011-06-18 19:29:38 UTC
On powerpc-apple-darwin9 at revision 175158 g++.dg/ext/altivec-17.C fails with

FAIL: g++.dg/ext/altivec-17.C  (test for errors, line 15)
FAIL: g++.dg/ext/altivec-17.C (test for excess errors)
Excess errors:
/opt/gcc/work/gcc/testsuite/g++.dg/ext/altivec-17.C:15:24: error: invalid initialization of reference of type 'const simd_type& {aka const __vector(4) unsigned int&}' from expression of type 'const bool_simd_type {aka const __vector(4) __bool int}'

which does not match the dg-error "'const simd_type&' from expression of type 'const bool_simd_type'".
The fix should be similar to the one for pr49432 (note that it is likely also a 4.6 regression).
Comment 1 Mikael Pettersson 2011-06-18 23:54:51 UTC
(In reply to comment #0)
> (note that it is likely also a 4.6 regression).

It is, g++.dg/ext/altivec-17.c fails for me on powerpc64-linux with gcc-4.6-20110617, while it didn't fail with gcc-4.6-20110610.
Comment 2 Dominique d'Humieres 2011-06-20 11:00:17 UTC
What would be the "best fix" between the two?

--- /opt/gcc/_gcc_clean/gcc/testsuite/g++.dg/ext/altivec-17.C	2010-07-08 10:41:46.000000000 +0200
+++ /opt/gcc/work/gcc/testsuite/g++.dg/ext/altivec-17.C	2011-06-20 12:46:32.000000000 +0200
@@ -12,5 +12,5 @@ typedef vector__ bool__ int bool_simd_ty
 
 void Foo (bool_simd_type const &a)
 {
-  simd_type const &v = a; // { dg-error "'const simd_type&' from expression of type 'const bool_simd_type'" }
+  simd_type const &v = a; // { dg-error "'const simd_type& {aka \[^\n\r\}\]*}' from expression of type 'const bool_simd_type {aka \[^\n\r\}\]*}'" }
 }

or

--- /opt/gcc/_gcc_clean/gcc/testsuite/g++.dg/ext/altivec-17.C	2010-07-08 10:41:46.000000000 +0200
+++ /Users/dominiq/Desktop/altivec-17.C	2011-06-20 12:01:18.000000000 +0200
@@ -12,5 +12,5 @@ typedef vector__ bool__ int bool_simd_ty
 
 void Foo (bool_simd_type const &a)
 {
-  simd_type const &v = a; // { dg-error "'const simd_type&' from expression of type 'const bool_simd_type'" }
+  simd_type const &v = a; // { dg-error "'const simd_type& {aka const __vector\\\(4\\\) unsigned int&}' from expression of type 'const bool_simd_type {aka const __vector\\\(4\\\) __bool int}'" }
 }
Comment 3 Dominique d'Humieres 2011-09-07 12:24:06 UTC
Fixed by revision 178614 (see http://gcc.gnu.org/ml/gcc-testresults/2011-09/msg00597.html )

Author:	meissner
Date:	Tue Sep 6 22:06:59 2011 UTC (13 hours, 56 minutes ago)
Changed paths:	2
Log Message:	
Fix altivec-17.C to match current compiler error message