Commit b851ea09 by Richard Kenner

(copy_rtx_if_shared): A CONST can be shared if it contains a

SYBOL_REF.

From-SVN: r2923
parent 818b11b9
...@@ -1267,6 +1267,15 @@ copy_rtx_if_shared (orig) ...@@ -1267,6 +1267,15 @@ copy_rtx_if_shared (orig)
/* SCRATCH must be shared because they represent distinct values. */ /* SCRATCH must be shared because they represent distinct values. */
return x; return x;
case CONST:
/* CONST can be shared if it contains a SYMBOL_REF. If it contains
a LABEL_REF, it isn't sharable. */
if (GET_CODE (XEXP (x, 0)) == PLUS
&& GET_CODE (XEXP (XEXP (x, 0), 0)) == SYMBOL_REF
&& GET_CODE (XEXP (XEXP (x, 0), 1)) == CONST_INT)
return x;
break;
case INSN: case INSN:
case JUMP_INSN: case JUMP_INSN:
case CALL_INSN: case CALL_INSN:
......
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