rs6000 - add speculation_barrier pattern
authorRichard Earnshaw <rearnsha@arm.com>
Wed, 1 Aug 2018 08:16:48 +0000 (08:16 +0000)
committerRichard Earnshaw <rearnsha@gcc.gnu.org>
Wed, 1 Aug 2018 08:16:48 +0000 (08:16 +0000)
This patch reworks the existing rs6000_speculation_barrier pattern to
work with the new __builtin_sepculation_safe_value() intrinsic.  The
change is trivial as it simply requires renaming the existing speculation
barrier pattern.

So the total patch is to delete 14 characters!

* config/rs6000/rs6000.md (speculation_barrier): Renamed from
rs6000_speculation_barrier.
* config/rs6000/rs6000.c (rs6000_expand_builtin): Adjust for
new barrier pattern name.

From-SVN: r263197

gcc/ChangeLog
gcc/config/rs6000/rs6000.c
gcc/config/rs6000/rs6000.md

index 6b2e93bb48a381b0bfded20e92d0d1e8b5f61984..54cd8f91020f1f3753ae8dd642cc244e19ce70e3 100644 (file)
@@ -1,3 +1,10 @@
+2018-08-01  Richard Earnshaw  <rearnsha@arm.com>
+
+       * config/rs6000/rs6000.md (speculation_barrier): Renamed from
+       rs6000_speculation_barrier.
+       * config/rs6000/rs6000.c (rs6000_expand_builtin): Adjust for
+       new barrier pattern name.
+
 2018-08-01  Richard Earnshaw  <rearnsha@arm.com>
 
        * config/i386/i386.md (unspecv): Add UNSPECV_SPECULATION_BARRIER.
index 30403828c46569991fad4fb4e23ed7fda36651fd..c2af4b869073c082877db069c99b5239bca69172 100644 (file)
@@ -15836,7 +15836,7 @@ rs6000_expand_builtin (tree exp, rtx target, rtx subtarget ATTRIBUTE_UNUSED,
 
     case MISC_BUILTIN_SPEC_BARRIER:
       {
-       emit_insn (gen_rs6000_speculation_barrier ());
+       emit_insn (gen_speculation_barrier ());
        return NULL_RTX;
       }
 
index 56b8a30fef60658cbfefc8f3152edd1b6d2ffd48..d70b01b8ca78c98e0b334ad1f1b84716246d88db 100644 (file)
   return "ori 2,2,0";
 })
 
-(define_insn "rs6000_speculation_barrier"
+(define_insn "speculation_barrier"
   [(unspec_volatile:BLK [(const_int 0)] UNSPECV_SPEC_BARRIER)]
   ""
   "ori 31,31,0")