Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/gcc.dg/store_merging_9.c @ 111:04ced10e8804
gcc 7
author | kono |
---|---|
date | Fri, 27 Oct 2017 22:46:09 +0900 |
parents | |
children |
line wrap: on
line source
/* PR tree-optimization/82434 */ /* { dg-do compile } */ /* { dg-require-effective-target store_merge } */ /* { dg-options "-O2 -fdump-tree-store-merging" } */ enum E { E0, E1, E2 = __INT_MAX__, E3 = -__INT_MAX__ - 1 }; struct bar { enum E a; char b; _Bool c; short d; }; void foo1 (struct bar *p) { p->b = 0; p->a = E0; p->c = (_Bool) 0; p->d = 0; } void foo2 (struct bar *p) { p->b = 0; p->a = E0; p->c = (_Bool) 1; p->d = 0; } /* { dg-final { scan-tree-dump-times "Merging successful" 2 "store-merging" } } */