diff options
author | Richard Guenther <rguenther@suse.de> | 2006-08-22 16:26:32 +0000 |
---|---|---|
committer | Richard Guenther <rguenther@suse.de> | 2006-08-22 16:26:32 +0000 |
commit | bde235d2337256726c059f0093add2b80dd40ed5 (patch) | |
tree | 2a5f3f06f213f2d53444674a77ae2fb00b1cd032 /gcc/testsuite/gcc.c-torture | |
parent | 8dddca1e18d346975c8910ca2c2a76381872c5a5 (diff) |
2006-08-22 Richard Guenther <rguenther@suse.de>
PR middle-end/28776
* tree-scalar-evolution.c (fold_used_pointer): Add at_stmt
parameter. Convert arguments to arithmetic expression to the
chrecs type.
(analyze_scalar_evolution_1): Adjust caller.
* gcc.c-torture/compile/pr28776-1.c: New testcase.
* gcc.c-torture/compile/pr28776-2.c: Likewise.
git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@116326 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/gcc.c-torture')
-rw-r--r-- | gcc/testsuite/gcc.c-torture/compile/pr28776-1.c | 16 | ||||
-rw-r--r-- | gcc/testsuite/gcc.c-torture/compile/pr28776-2.c | 26 |
2 files changed, 42 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.c-torture/compile/pr28776-1.c b/gcc/testsuite/gcc.c-torture/compile/pr28776-1.c new file mode 100644 index 00000000000..a37fb6fe105 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/pr28776-1.c @@ -0,0 +1,16 @@ +typedef struct dw_fde_struct +{ + int decl; +} *dw_fde_ref; +dw_fde_ref fde_table; +unsigned fde_table_in_use; +void output_call_frame_info (void) +{ + unsigned int i; + dw_fde_ref fde; + for (i = 0; i < fde_table_in_use; i++) + { + fde = &fde_table[i]; + tree_contains_struct_check_failed (fde_table[i].decl); + } +} diff --git a/gcc/testsuite/gcc.c-torture/compile/pr28776-2.c b/gcc/testsuite/gcc.c-torture/compile/pr28776-2.c new file mode 100644 index 00000000000..61a5d37dfa9 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/pr28776-2.c @@ -0,0 +1,26 @@ +typedef struct RangeCoder +{ + unsigned char one_state[256]; +} RangeCoder; +static inline void put_rac(RangeCoder *c, unsigned char* const state) +{ + *state= c->one_state[*state]; +} +typedef struct PlaneContext{ + unsigned (*state)[32]; +} PlaneContext; +static inline void put_symbol(RangeCoder *c, unsigned char *state) +{ + int i; + const int e; + put_rac(c, state); + for(i=e-1; i>=0; i--) + put_rac(c, state+22+i); +} +int encode_line(void) +{ + PlaneContext * const p; + RangeCoder * const c; + int a; + put_symbol(c, p->state[a]); +} |