Commit 42eb8bd1 by Jakub Jelinek Committed by Jakub Jelinek

re PR other/58712 (issues found by --enable-checking=valgrind)

	PR other/58712
	* read-rtl.c (read_rtx_code): Clear all of RTX_CODE_SIZE (code).
	For REGs set ORIGINAL_REGNO.

From-SVN: r207230
parent 4a271b7e
2014-01-29 Jakub Jelinek <jakub@redhat.com>
PR other/58712
* read-rtl.c (read_rtx_code): Clear all of RTX_CODE_SIZE (code).
For REGs set ORIGINAL_REGNO.
2014-01-29 Bingfeng Mei <bmei@broadcom.com> 2014-01-29 Bingfeng Mei <bmei@broadcom.com>
* doc/md.texi: Mention that a target shouldn't implement * doc/md.texi: Mention that a target shouldn't implement
......
...@@ -1131,6 +1131,7 @@ read_rtx_code (const char *code_name) ...@@ -1131,6 +1131,7 @@ read_rtx_code (const char *code_name)
/* If we end up with an insn expression then we free this space below. */ /* If we end up with an insn expression then we free this space below. */
return_rtx = rtx_alloc (code); return_rtx = rtx_alloc (code);
format_ptr = GET_RTX_FORMAT (code); format_ptr = GET_RTX_FORMAT (code);
memset (return_rtx, 0, RTX_CODE_SIZE (code));
PUT_CODE (return_rtx, code); PUT_CODE (return_rtx, code);
if (iterator) if (iterator)
...@@ -1154,6 +1155,8 @@ read_rtx_code (const char *code_name) ...@@ -1154,6 +1155,8 @@ read_rtx_code (const char *code_name)
/* 0 means a field for internal use only. /* 0 means a field for internal use only.
Don't expect it to be present in the input. */ Don't expect it to be present in the input. */
case '0': case '0':
if (code == REG)
ORIGINAL_REGNO (return_rtx) = REGNO (return_rtx);
break; break;
case 'e': case 'e':
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment