Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/g++.dg/vect/slp-pr56812.cc @ 131:84e7813d76e9
gcc-8.2
author | mir3636 |
---|---|
date | Thu, 25 Oct 2018 07:37:49 +0900 |
parents | 04ced10e8804 |
children |
line wrap: on
line source
/* { dg-do compile } */ /* { dg-require-effective-target vect_float } */ /* { dg-require-effective-target vect_hw_misalign } */ /* { dg-additional-options "-O3 -funroll-loops -fvect-cost-model=dynamic -fopt-info-vec" } */ class mydata { public: mydata() {Set(-1.0);} void Set (float); static int upper() {return 8;} float data[8]; }; void mydata::Set (float x) { /* We want to vectorize this either as loop or basic-block. */ for (int i=0; i<upper(); i++) /* { dg-optimized "\[^\n\]* vectorized" } */ data[i] = x; }