This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/16337] New: bug defining multiple altivec vectors in same C++ statement


When multiple vector variables are defined in the same C++ statement
the compiler doesn't recognize the ones after the first as vectors.
This test case, extracted from g++.dg/ext/altivec-3.C, fails with g++
built from 20040630 sources; I don't currently have a newer compiler to
test with.  The original test has been failing for awhile because of
other problems with variable argument lists, so this problem might not
have been noticed by anyone yet.
                                                                               
                
Test case:
                                                                               
                
#include <altivec.h>
                                                                               
                
vector signed int foo (void)
{
    vector signed int v1 = { 1, 2, 3, 4 };
    vector signed int v2, v3;
    vector signed int v4;
    v2 = v1;
    v3 = v1;
    v4 = v1;
}
                                                                               
                
ouput:
                                                                               
                
madcow% $GXX -c -maltivec bug.C
bug.C: In function `int __vector__ foo()':
bug.C:9: error: cannot convert `int __vector__' to `int' in assignment
                                                                               
                
This is using a biarch powerpc64-linux GCC.  I think this is a recent
regression on mainline.

-- 
           Summary: bug defining multiple altivec vectors in same C++
                    statement
           Product: gcc
           Version: 3.5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: janis187 at us dot ibm dot com
                CC: gcc-bugs at gcc dot gnu dot org
GCC target triplet: powerpc-linux


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16337


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]