diff options
author | Michael Matz <matz@suse.de> | 2006-11-13 14:36:47 +0000 |
---|---|---|
committer | Michael Matz <matz@gcc.gnu.org> | 2006-11-13 14:36:47 +0000 |
commit | 7180bcb13f880a38300059209b227cd487277186 (patch) | |
tree | 4466a13ea14fee1563383886e3034e79d733a8bc /gcc | |
parent | 3e806a3df4fdd07fbe13b7dd17676999f7bd6f28 (diff) | |
download | gcc-7180bcb13f880a38300059209b227cd487277186.zip gcc-7180bcb13f880a38300059209b227cd487277186.tar.gz gcc-7180bcb13f880a38300059209b227cd487277186.tar.bz2 |
* genemit.c (gen_expand): Allocate enough memory.
From-SVN: r118762
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 4 | ||||
-rw-r--r-- | gcc/genemit.c | 3 |
2 files changed, 6 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 00039dc0..cc496e1 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,7 @@ +2006-11-13 Michael Matz <matz@suse.de> + + * genemit.c (gen_expand): Allocate enough memory. + 2006-11-13 Joseph Myers <joseph@codesourcery.com> * config/arm/bpapi.h (TARGET_BPABI_CPP_BUILTINS): Define diff --git a/gcc/genemit.c b/gcc/genemit.c index a1ebcf6..b0dd234 100644 --- a/gcc/genemit.c +++ b/gcc/genemit.c @@ -534,7 +534,8 @@ gen_expand (rtx expand) Use emit_insn to add them to the sequence being accumulated. But don't do this if the user's code has set `no_more' nonzero. */ - used = XCNEWVEC (char, operands); + used = XCNEWVEC (char, + MAX (operands, MAX (max_scratch_opno, max_dup_opno) + 1)); for (i = 0; i < XVECLEN (expand, 1); i++) { |