From 8c8ee7cee1b6ed6253ca27666a95a666cd4eea53 Mon Sep 17 00:00:00 2001 From: Jonas Paulsson Date: Thu, 7 Jan 2016 07:20:55 +0000 Subject: [PATCH] [SystemZ] Add hasSideEffects flag on Serialize instruction. Serialize will perform a hardware serialization operation, and is acting as a memory barrier. Therefore it must have the hasSideEffects flag set so it will be treated as a global memory object. Reviewed by Ulrich Weigand git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@257036 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/SystemZ/SystemZInstrInfo.td | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/Target/SystemZ/SystemZInstrInfo.td b/lib/Target/SystemZ/SystemZInstrInfo.td index b9f2eb5514a..d5dabc2cd6a 100644 --- a/lib/Target/SystemZ/SystemZInstrInfo.td +++ b/lib/Target/SystemZ/SystemZInstrInfo.td @@ -1219,6 +1219,9 @@ def PFDRL : PrefetchRILPC<"pfdrl", 0xC62, z_prefetch>; // Atomic operations //===----------------------------------------------------------------------===// +// A serialization instruction that acts as a barrier for all memory +// accesses, which expands to "bcr 14, 0". +let hasSideEffects = 1 in def Serialize : Alias<2, (outs), (ins), [(z_serialize)]>; let Predicates = [FeatureInterlockedAccess1], Defs = [CC] in { -- 2.34.1