[committed][AArch64] Fix memmodel index in aarch64_store_exclusive_pair

Richard Sandiford richard.sandiford@arm.com
Mon Sep 23 09:25:00 GMT 2019


Found via an rtl checking failure.  Tested on aarch64-linux-gnu
and applied as obvious (r276052).

Richard


2019-09-23  Richard Sandiford  <richard.sandiford@arm.com>

gcc/
	* config/aarch64/atomics.md (aarch64_store_exclusive_pair): Fix
	memmodel index.

Index: gcc/config/aarch64/atomics.md
===================================================================
--- gcc/config/aarch64/atomics.md	2019-09-21 13:56:09.071933423 +0100
+++ gcc/config/aarch64/atomics.md	2019-09-23 10:22:47.361697048 +0100
@@ -752,7 +752,7 @@ (define_insn "aarch64_store_exclusive_pa
 	  UNSPECV_SX))]
   ""
   {
-    enum memmodel model = memmodel_from_int (INTVAL (operands[3]));
+    enum memmodel model = memmodel_from_int (INTVAL (operands[4]));
     if (is_mm_relaxed (model) || is_mm_consume (model) || is_mm_acquire (model))
       return "stxp\t%w0, %x2, %x3, %1";
     else



More information about the Gcc-patches mailing list