diff options
author | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-06-23 11:51:34 +0000 |
---|---|---|
committer | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-06-23 11:51:34 +0000 |
commit | bbdb51dab528e036011e8a91eb9b4475975341a3 (patch) | |
tree | dd142a166873f8566f124516b14bfcaaa82144dc /gcc/testsuite/gcc.dg/pr36508.c | |
parent | a60ff1869d37fc3be3837b29706fbb51522886f6 (diff) | |
download | gcc-bbdb51dab528e036011e8a91eb9b4475975341a3.tar.gz |
PR tree-optimization/36508
* tree-ssa-pre.c (compute_antic): Allow num_iterations up to
499, don't check it at all in release compilers.
* gcc.dg/pr36508.c: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@137036 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/gcc.dg/pr36508.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/pr36508.c | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/pr36508.c b/gcc/testsuite/gcc.dg/pr36508.c new file mode 100644 index 00000000000..30489923642 --- /dev/null +++ b/gcc/testsuite/gcc.dg/pr36508.c @@ -0,0 +1,29 @@ +/* PR tree-optimization/36508 */ +/* { dg-do compile } */ +/* { dg-options "-O -ftree-pre" } */ + +void +foo (short *sp) +{ + int k; + k = 1; +#define SP0 *sp++ = 1; + while (1) + { + if (k > 6) + break; + SP0 + k++; + } + k = 1; + while (1) + { + if (k > 6) + break; + SP0 + k++; + } +#define SP1 SP0 SP0 SP0 SP0 SP0 SP0 SP0 SP0 SP0 SP0 SP0 +#define SP2 SP1 SP1 SP1 SP1 SP1 SP1 SP1 SP1 SP1 SP1 SP1 + SP2 +} |