diff mbox

[1/6] c6x: Fix for RTL checking

Message ID f039ecf3fb7453b3d7ccf6e941164e0dabde055e.1487685472.git.segher@kernel.crashing.org
State New
Headers show

Commit Message

Segher Boessenkool Feb. 21, 2017, 2:48 p.m. UTC
2017-02-21  Segher Boessenkool  <segher@kernel.crashing.org>

	* config/c6x/c6x.c (predicate_insn): Do not incorrectly share RTL.

---
 gcc/config/c6x/c6x.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Bernd Schmidt Feb. 21, 2017, 3:03 p.m. UTC | #1
On 02/21/2017 03:48 PM, Segher Boessenkool wrote:
> 2017-02-21  Segher Boessenkool  <segher@kernel.crashing.org>
>
> 	* config/c6x/c6x.c (predicate_insn): Do not incorrectly share RTL.

Ok, thanks.


Bernd
diff mbox

Patch

diff --git a/gcc/config/c6x/c6x.c b/gcc/config/c6x/c6x.c
index 84bfdfa..42b773b 100644
--- a/gcc/config/c6x/c6x.c
+++ b/gcc/config/c6x/c6x.c
@@ -3800,6 +3800,7 @@  predicate_insn (rtx_insn *insn, rtx cond, bool doit)
     {
       if (doit)
 	{
+	  cond = copy_rtx (cond);
 	  rtx newpat = gen_rtx_COND_EXEC (VOIDmode, cond, PATTERN (insn));
 	  PATTERN (insn) = newpat;
 	  INSN_CODE (insn) = -1;