summaryrefslogtreecommitdiff
path: root/gcc/tree-vrp.c
diff options
context:
space:
mode:
authorjsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4>2008-08-29 23:30:18 +0000
committerjsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4>2008-08-29 23:30:18 +0000
commit1c7857f5fadc74480ca25960e5f8c50496e82f60 (patch)
tree32335413daebce13b9d8208c0a878230201efda1 /gcc/tree-vrp.c
parent43bf2fc511e63c6b47f5b4e1c7cefb3a986565f3 (diff)
downloadgcc-1c7857f5fadc74480ca25960e5f8c50496e82f60.tar.gz
PR bootstrap/37086
* tree-vrp.c (find_switch_asserts): Make idx volatile for GCC versions before 4.0. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@139792 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-vrp.c')
-rw-r--r--gcc/tree-vrp.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/tree-vrp.c b/gcc/tree-vrp.c
index 7579ee1330b..348382ecae3 100644
--- a/gcc/tree-vrp.c
+++ b/gcc/tree-vrp.c
@@ -4333,7 +4333,12 @@ find_switch_asserts (basic_block bb, gimple last)
edge e;
tree vec2;
size_t n = gimple_switch_num_labels(last);
+#if GCC_VERSION >= 4000
unsigned int idx;
+#else
+ /* Work around GCC 3.4 bug (PR 37086). */
+ volatile unsigned int idx;
+#endif
need_assert = false;
bsi = gsi_for_stmt (last);