From: Andreas Sandberg Date: Tue, 14 May 2013 13:06:50 +0000 (+0200) Subject: arm: Add support for the m5fail pseudo-op X-Git-Tag: stable_2013_10_14~117 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=1ae30c68c1f5159a5e1c557ee33a33aa695d7da5;p=gem5.git arm: Add support for the m5fail pseudo-op --- diff --git a/src/arch/arm/isa/formats/m5ops.isa b/src/arch/arm/isa/formats/m5ops.isa index 1eb7d3f65..26210af0b 100644 --- a/src/arch/arm/isa/formats/m5ops.isa +++ b/src/arch/arm/isa/formats/m5ops.isa @@ -53,6 +53,7 @@ def format M5ops() {{ case 0x11: return new Deprecated_ivle(machInst); case 0x20: return new Deprecated_exit (machInst); case 0x21: return new M5exit(machInst); + case 0x22: return new M5fail(machInst); case 0x31: return new Loadsymbol(machInst); case 0x30: return new Initparam(machInst); case 0x40: return new Resetstats(machInst); diff --git a/src/arch/arm/isa/insts/m5ops.isa b/src/arch/arm/isa/insts/m5ops.isa index 272f16b17..06ed34af8 100644 --- a/src/arch/arm/isa/insts/m5ops.isa +++ b/src/arch/arm/isa/insts/m5ops.isa @@ -179,6 +179,17 @@ let {{ decoder_output += BasicConstructor.subst(m5exitIop) exec_output += PredOpExecute.subst(m5exitIop) + m5fail_code = ''' + PseudoInst::m5fail(xc->tcBase(), join32to64(R1, R0), join32to64(R3, R2)); + ''' + m5failIop = InstObjParams("m5fail", "M5fail", "PredOp", + { "code": m5fail_code, + "predicate_test": predicateTest }, + ["No_OpClass", "IsNonSpeculative"]) + header_output += BasicDeclare.subst(m5failIop) + decoder_output += BasicConstructor.subst(m5failIop) + exec_output += PredOpExecute.subst(m5failIop) + loadsymbolCode = ''' PseudoInst::loadsymbol(xc->tcBase()); ''' diff --git a/util/m5/m5op_arm.S b/util/m5/m5op_arm.S index 115c7a017..3a43913f7 100644 --- a/util/m5/m5op_arm.S +++ b/util/m5/m5op_arm.S @@ -90,6 +90,7 @@ SIMPLE_OP(quiesceTime, quiescetime_func, 0) SIMPLE_OP(rpns, rpns_func, 0) SIMPLE_OP(wakeCPU, wakecpu_func, 0) SIMPLE_OP(m5_exit, exit_func, 0) +SIMPLE_OP(m5_fail, fail_func, 0) SIMPLE_OP(m5_initparam, initparam_func, 0) SIMPLE_OP(m5_loadsymbol, loadsymbol_func, 0) SIMPLE_OP(m5_reset_stats, resetstats_func, 0)