ARM: Get rid of the unused Jump format.
authorGabe Black <gblack@eecs.umich.edu>
Wed, 2 Jun 2010 17:58:02 +0000 (12:58 -0500)
committerGabe Black <gblack@eecs.umich.edu>
Wed, 2 Jun 2010 17:58:02 +0000 (12:58 -0500)
src/arch/arm/insts/branch.cc
src/arch/arm/insts/branch.hh
src/arch/arm/isa/formats/branch.isa

index 3deb380f8dc06bf12169e05ac3dec20d4910566c..5e08b069d8b979b871a918be32c3747d5b26d551 100644 (file)
@@ -38,14 +38,6 @@ Branch::branchTarget(Addr branchPC) const
     return branchPC + 8 + disp;
 }
 
-Addr
-Jump::branchTarget(ThreadContext *tc) const
-{
-    Addr NPC = tc->readPC() + 8;
-    uint64_t Rb = tc->readIntReg(_srcRegIdx[0]);
-    return (Rb & ~3) | (NPC & 1);
-}
-
 const std::string &
 PCDependentDisassembly::disassemble(Addr pc,
                                     const SymbolTable *symtab) const
@@ -90,12 +82,4 @@ BranchExchange::generateDisassembly(Addr pc, const SymbolTable *symtab) const
     }
     return ss.str();
 }
-
-std::string
-Jump::generateDisassembly(Addr pc, const SymbolTable *symtab) const
-{
-    std::stringstream ss;
-    printMnemonic(ss);
-    return ss.str();
-}
 }
index c9a4eaf40776a3c99f5caacf4257bd005632ce63..db626f28f71d9bd27dcc35c8d4e993a321cc5f0e 100644 (file)
@@ -107,33 +107,6 @@ class BranchExchange : public PredOp
     generateDisassembly(Addr pc, const SymbolTable *symtab) const;
 };
 
-
-/**
- * Base class for jumps (register-indirect control transfers).  In
- * the Arm ISA, these are always unconditional.
- */
-class Jump : public PCDependentDisassembly
-{
-  protected:
-
-    /// Displacement to target address (signed).
-    int32_t disp;
-
-    uint32_t target;
-
-  public:
-    /// Constructor
-    Jump(const char *mnem, ExtMachInst _machInst, OpClass __opClass)
-        : PCDependentDisassembly(mnem, _machInst, __opClass),
-          disp(machInst.offset << 2)
-    {
-    }
-
-    Addr branchTarget(ThreadContext *tc) const;
-
-    std::string
-    generateDisassembly(Addr pc, const SymbolTable *symtab) const;
-};
 }
 
 #endif //__ARCH_ARM_INSTS_BRANCH_HH__
index 5f1b541ffdf57950614023099ffb820b1df84cba..efe91f039597d8a47366fd3520cceaee8cfc26bd 100644 (file)
@@ -108,24 +108,3 @@ def format BranchExchange(code,*opt_flags) {{
     exec_output = BasicExecute.subst(iop)
 }};
 
-def format Jump(code, *opt_flags) {{
-    #Build Instruction Flags
-    #Use Link Flag to Add Link Code
-    inst_flags = ('IsIndirectControl', 'IsUncondControl')
-    for x in opt_flags:
-        if x == 'Link':
-            code = 'LR = NPC;\n' + code
-        elif x == 'ClearHazards':
-            code += '/* Code Needed to Clear Execute & Inst Hazards */\n'
-        else:
-            inst_flags += (x, )
-
-    iop = InstObjParams(name, Name, 'Jump', code, inst_flags)
-    header_output = BasicDeclare.subst(iop)
-    decoder_output = BasicConstructor.subst(iop)
-    decode_block = BasicDecode.subst(iop)
-    exec_output = BasicExecute.subst(iop)
-    #exec_output = PredOpExecute.subst(iop)
-}};
-
-