diff options
author | Bernd Schmidt <bernds@cygnus.co.uk> | 2000-03-13 19:35:38 +0000 |
---|---|---|
committer | Bernd Schmidt <crux@gcc.gnu.org> | 2000-03-13 19:35:38 +0000 |
commit | f0c988c8238ee6c46c86200cda553592c97a6679 (patch) | |
tree | 3856ea30946d782b083a8d40bdc068ea5162f840 /gcc | |
parent | 93ca4ba7663487de66e5aff1dc46722079f84e4d (diff) | |
download | gcc-f0c988c8238ee6c46c86200cda553592c97a6679.zip gcc-f0c988c8238ee6c46c86200cda553592c97a6679.tar.gz gcc-f0c988c8238ee6c46c86200cda553592c97a6679.tar.bz2 |
Fix recently introduced error in expand_end_case.
From-SVN: r32511
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/stmt.c | 3 |
2 files changed, 8 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index a6faefc..1589abd 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2000-03-13 Bernd Schmidt <bernds@cygnus.co.uk> + + * stmt.c (expand_end_case): RANGE may be signed, and when checking + whether it is too large we must also verify that it isn't negative. + 2000-03-13 Jakub Jelinek <jakub@redhat.com> * config/sparc/sparc.md: Remove all traces of TARGET_LIVE_G0. @@ -5402,6 +5402,9 @@ expand_end_case (orig_index) else if (count < CASE_VALUES_THRESHOLD || compare_tree_int (range, 10 * count) > 0 + /* RANGE may be signed, and really large ranges will show up + as negative numbers. */ + || compare_tree_int (range, 0) < 0 #ifndef ASM_OUTPUT_ADDR_DIFF_ELT || flag_pic #endif |