mem.isa (7119:5ad962dec52f) | mem.isa (7132:83b433d6e600) |
---|---|
1// -*- mode:c++ -*- 2 3// Copyright (c) 2010 ARM Limited 4// All rights reserved 5// 6// The license below extends only to copyright in the software and shall 7// not be construed as granting a license to any other intellectual 8// property including but not limited to intellectual property relating --- 24 unchanged lines hidden (view full) --- 33// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 34// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 35// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 36// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 37// 38// Authors: Gabe Black 39 40let {{ | 1// -*- mode:c++ -*- 2 3// Copyright (c) 2010 ARM Limited 4// All rights reserved 5// 6// The license below extends only to copyright in the software and shall 7// not be construed as granting a license to any other intellectual 8// property including but not limited to intellectual property relating --- 24 unchanged lines hidden (view full) --- 33// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 34// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 35// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 36// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 37// 38// Authors: Gabe Black 39 40let {{ |
41 def newLoadStoreBase(name, Name, imm, eaCode, accCode, memFlags, 42 instFlags, base = 'MemoryNew', execTemplateBase = ''): | 41 def loadStoreBase(name, Name, imm, eaCode, accCode, memFlags, 42 instFlags, base = 'Memory', execTemplateBase = ''): |
43 # Make sure flags are in lists (convert to lists if not). 44 memFlags = makeList(memFlags) 45 instFlags = makeList(instFlags) 46 47 # This shouldn't be part of the eaCode, but until the exec templates 48 # are converted over it's the easiest place to put it. 49 eaCode += '\n unsigned memAccessFlags = ' 50 if memFlags: --- 75 unchanged lines hidden (view full) --- 126 memSuffix = '.ub' 127 else: 128 raise Exception, "Unrecognized size for load %d" % size 129 130 return memSuffix 131 132 def buildMemBase(base, post, writeback): 133 if post and writeback: | 43 # Make sure flags are in lists (convert to lists if not). 44 memFlags = makeList(memFlags) 45 instFlags = makeList(instFlags) 46 47 # This shouldn't be part of the eaCode, but until the exec templates 48 # are converted over it's the easiest place to put it. 49 eaCode += '\n unsigned memAccessFlags = ' 50 if memFlags: --- 75 unchanged lines hidden (view full) --- 126 memSuffix = '.ub' 127 else: 128 raise Exception, "Unrecognized size for load %d" % size 129 130 return memSuffix 131 132 def buildMemBase(base, post, writeback): 133 if post and writeback: |
134 base = "MemoryNewPostIndex<%s>" % base | 134 base = "MemoryPostIndex<%s>" % base |
135 elif not post and writeback: | 135 elif not post and writeback: |
136 base = "MemoryNewPreIndex<%s>" % base | 136 base = "MemoryPreIndex<%s>" % base |
137 elif not post and not writeback: | 137 elif not post and not writeback: |
138 base = "MemoryNewOffset<%s>" % base | 138 base = "MemoryOffset<%s>" % base |
139 else: 140 raise Exception, "Illegal combination of post and writeback" 141 return base 142}}; 143 | 139 else: 140 raise Exception, "Illegal combination of post and writeback" 141 return base 142}}; 143 |