pred_inst.hh (7639:8c09b7ff5b57) pred_inst.hh (7720:65d338a8dba4)
1/*
2 * Copyright (c) 2010 ARM Limited
3 * All rights reserved
4 *
5 * The license below extends only to copyright in the software and shall
6 * not be construed as granting a license to any other intellectual
7 * property including but not limited to intellectual property relating
8 * to a hardware implementation of the functionality of the software

--- 298 unchanged lines hidden (view full) ---

307
308 ~PredMacroOp()
309 {
310 if (numMicroops)
311 delete [] microOps;
312 }
313
314 StaticInstPtr
1/*
2 * Copyright (c) 2010 ARM Limited
3 * All rights reserved
4 *
5 * The license below extends only to copyright in the software and shall
6 * not be construed as granting a license to any other intellectual
7 * property including but not limited to intellectual property relating
8 * to a hardware implementation of the functionality of the software

--- 298 unchanged lines hidden (view full) ---

307
308 ~PredMacroOp()
309 {
310 if (numMicroops)
311 delete [] microOps;
312 }
313
314 StaticInstPtr
315 fetchMicroop(MicroPC microPC)
315 fetchMicroop(MicroPC microPC) const
316 {
317 assert(microPC < numMicroops);
318 return microOps[microPC];
319 }
320
321 std::string generateDisassembly(Addr pc, const SymbolTable *symtab) const;
322};
323
324/**
325 * Base class for predicated micro-operations.
326 */
327class PredMicroop : public PredOp
328{
329 /// Constructor
330 PredMicroop(const char *mnem, ExtMachInst _machInst, OpClass __opClass) :
331 PredOp(mnem, _machInst, __opClass)
332 {
333 flags[IsMicroop] = true;
334 }
316 {
317 assert(microPC < numMicroops);
318 return microOps[microPC];
319 }
320
321 std::string generateDisassembly(Addr pc, const SymbolTable *symtab) const;
322};
323
324/**
325 * Base class for predicated micro-operations.
326 */
327class PredMicroop : public PredOp
328{
329 /// Constructor
330 PredMicroop(const char *mnem, ExtMachInst _machInst, OpClass __opClass) :
331 PredOp(mnem, _machInst, __opClass)
332 {
333 flags[IsMicroop] = true;
334 }
335
336 void
337 advancePC(PCState &pcState) const
338 {
339 if (flags[IsLastMicroop])
340 pcState.uEnd();
341 else
342 pcState.uAdvance();
343 }
335};
336}
337
338#endif //__ARCH_ARM_INSTS_PREDINST_HH__
344};
345}
346
347#endif //__ARCH_ARM_INSTS_PREDINST_HH__