gencodes.c (main): Make LAST_INSN_CODE higher than any insn code, rather than any named insn's code.

gcc/
	* gencodes.c (main): Make LAST_INSN_CODE higher than any insn code,
	rather than any named insn's code.

From-SVN: r210963
This commit is contained in:
Richard Sandiford 2014-05-27 10:05:55 +00:00 committed by Richard Sandiford
parent d9f99ec416
commit 9921417d94
2 changed files with 12 additions and 3 deletions

View File

@ -1,3 +1,8 @@
2014-05-27 Richard Sandiford <rdsandiford@googlemail.com>
* gencodes.c (main): Make LAST_INSN_CODE higher than any insn code,
rather than any named insn's code.
2014-05-27 Georg-Johann Lay <avr@gjlay.de>
PR libgcc/61152

View File

@ -50,6 +50,7 @@ int
main (int argc, char **argv)
{
rtx desc;
int last = 1;
progname = "gencodes";
@ -82,13 +83,16 @@ enum insn_code {\n\
break;
if (GET_CODE (desc) == DEFINE_INSN || GET_CODE (desc) == DEFINE_EXPAND)
gen_insn (desc, insn_code_number);
{
gen_insn (desc, insn_code_number);
last = insn_code_number + 1;
}
}
puts (" LAST_INSN_CODE\n\
printf (" LAST_INSN_CODE = %d\n\
};\n\
\n\
#endif /* GCC_INSN_CODES_H */");
#endif /* GCC_INSN_CODES_H */\n", last);
if (ferror (stdout) || fflush (stdout) || fclose (stdout))
return FATAL_EXIT_CODE;