summaryrefslogtreecommitdiff
path: root/src/arch/x86/isa/insts/arithmetic/add_and_subtract.py
diff options
context:
space:
mode:
authorSteve Reinhardt <stever@eecs.umich.edu>2007-06-22 09:24:33 -0700
committerSteve Reinhardt <stever@eecs.umich.edu>2007-06-22 09:24:33 -0700
commit4d1bcbcd36e5735e76b38abb151de716c31a2272 (patch)
tree58c29ad6905c45332e1d1d12b9d66596ae6d30d4 /src/arch/x86/isa/insts/arithmetic/add_and_subtract.py
parentbdd5fd20fb19eb52ef812cd284094e5513646e36 (diff)
parent470a6a9a74eb28a5052e6492c0a3aa9724c57500 (diff)
downloadgem5-4d1bcbcd36e5735e76b38abb151de716c31a2272.tar.xz
Merge vm1.(none):/home/stever/bk/newmem-head
into vm1.(none):/home/stever/bk/newmem-cache2 --HG-- extra : convert_revision : 1da75335907fee2d1745ec13e515819dfe2aad89
Diffstat (limited to 'src/arch/x86/isa/insts/arithmetic/add_and_subtract.py')
-rw-r--r--src/arch/x86/isa/insts/arithmetic/add_and_subtract.py20
1 files changed, 8 insertions, 12 deletions
diff --git a/src/arch/x86/isa/insts/arithmetic/add_and_subtract.py b/src/arch/x86/isa/insts/arithmetic/add_and_subtract.py
index de66f70f3..809b9ac7c 100644
--- a/src/arch/x86/isa/insts/arithmetic/add_and_subtract.py
+++ b/src/arch/x86/isa/insts/arithmetic/add_and_subtract.py
@@ -56,26 +56,22 @@
microcode = '''
def macroop SUB_R_I
{
- subi "env.reg", "env.reg", "IMMEDIATE"
+ subi reg, reg, imm
};
def macroop SUB_M_I
{
- ld "NUM_INTREGS+1", 3, ["env.scale", "env.index", "env.base"], \
- "DISPLACEMENT"
- subi "NUM_INTREGS+1", "NUM_INTREGS+1", "IMMEDIATE"
- st "NUM_INTREGS+1", 3, ["env.scale", "env.index", "env.base"], \
- "DISPLACEMENT"
+ ld t1, ds, [scale, index, base], disp
+ subi t1, t1, imm
+ st t1, ds, [scale, index, base], disp
};
def macroop SUB_P_I
{
- rdip "NUM_INTREGS+7"
- ld "NUM_INTREGS+1", 3, ["env.scale", "env.index", "env.base"], \
- "DISPLACEMENT"
- subi "NUM_INTREGS+1", "NUM_INTREGS+1", "IMMEDIATE"
- st "NUM_INTREGS+1", 3, ["env.scale", "env.index", "env.base"], \
- "DISPLACEMENT"
+ rdip t7
+ ld t1, ds, [scale, index, base], disp
+ subi t1, t1, imm
+ st t1, ds, [scale, index, base], disp
};
'''
#let {{