arch-arm: Signal an event when executing store exclusives
authorNikos Nikoleris <nikos.nikoleris@arm.com>
Wed, 12 Jul 2017 12:49:24 +0000 (13:49 +0100)
committerNikos Nikoleris <nikos.nikoleris@arm.com>
Fri, 13 Oct 2017 08:41:08 +0000 (08:41 +0000)
When a store exclusive is executed, whether it is successful or not,
the exclusives monitor is cleared and therefore we need to signal an
event for the PE.

Change-Id: I383c88c769c0ac5f5d36c4b5d39c9681134d3a20
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/4480
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>

src/arch/arm/isa/insts/str.isa
src/arch/arm/isa/insts/str64.isa

index 3f595692a4d7d41e1712c2bb46ad50c996e5d86f..1c697d3ff6f4f5e4ce13cd75badf9954bd989420 100644 (file)
@@ -1,6 +1,6 @@
 // -*- mode:c++ -*-
 
-// Copyright (c) 2010-2011 ARM Limited
+// Copyright (c) 2010-2011,2017 ARM Limited
 // All rights reserved
 //
 // The license below extends only to copyright in the software and shall
@@ -228,7 +228,8 @@ let {{
 
         def __init__(self, *args, **kargs):
             super(StoreImmEx, self).__init__(*args, **kargs)
-            self.codeBlobs["postacc_code"] = "Result = !writeResult;"
+            self.codeBlobs["postacc_code"] = \
+                  "Result = !writeResult; SevMailbox = 1; LLSCLock = 0;"
 
     class StoreImm(StoreImmInst, StoreSingle):
         decConstBase = 'LoadStoreImm'
@@ -307,7 +308,8 @@ let {{
 
         def __init__(self, *args, **kargs):
             super(StoreDoubleImmEx, self).__init__(*args, **kargs)
-            self.codeBlobs["postacc_code"] = "Result = !writeResult;"
+            self.codeBlobs["postacc_code"] = \
+                  "Result = !writeResult; SevMailbox = 1; LLSCLock = 0;"
 
     class StoreDoubleImm(StoreImmInst, StoreDouble):
         decConstBase = 'LoadStoreDImm'
index c15dca16eddf25826cb5053b5983dad46343cbaf..0b153c1ec2d3ee89d6589c6777e16f8f6770c574 100644 (file)
@@ -1,6 +1,6 @@
 // -*- mode:c++ -*-
 
-// Copyright (c) 2011-2013 ARM Limited
+// Copyright (c) 2011-2013,2017 ARM Limited
 // All rights reserved
 //
 // The license below extends only to copyright in the software and shall
@@ -277,7 +277,8 @@ let {{
         execBase = 'StoreEx64'
         def __init__(self, *args, **kargs):
             super(StoreEx64, self).__init__(*args, **kargs)
-            self.codeBlobs["postacc_code"] = "XResult = !writeResult;"
+            self.codeBlobs["postacc_code"] = \
+                 "XResult = !writeResult; SevMailbox = 1; LLSCLock = 0;"
 
     def buildStores64(mnem, NameBase, size, flavor="normal"):
         StoreImm64(mnem, NameBase + "_IMM", size, flavor=flavor).emit()
@@ -343,7 +344,8 @@ let {{
         writeback = False
         def __init__(self, *args, **kargs):
             super(StoreImmDEx64, self).__init__(*args, **kargs)
-            self.codeBlobs["postacc_code"] = "XResult = !writeResult;"
+            self.codeBlobs["postacc_code"] = \
+                 "XResult = !writeResult; SevMailbox = 1; LLSCLock = 0;"
 
     class StoreRegU64(StoreReg64):
         decConstBase = 'LoadStoreRegU64'