1/* 2 * Copyright (c) 2003-2005 The Regents of The University of Michigan 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions are 7 * met: redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer; --- 20 unchanged lines hidden (view full) --- 29 */ 30 31#ifndef __CPU_STATIC_INST_HH__ 32#define __CPU_STATIC_INST_HH__ 33 34#include <bitset> 35#include <string> 36 |
37#include "base/bitfield.hh" |
38#include "base/hashmap.hh" 39#include "base/misc.hh" 40#include "base/refcnt.hh" 41#include "cpu/op_class.hh" 42#include "sim/host.hh" 43#include "arch/isa_traits.hh" 44 45// forward declarations --- 361 unchanged lines hidden (view full) --- 407 static void dumpDecodeCacheStats(); 408 409 /// Decode a machine instruction. 410 /// @param mach_inst The binary instruction to decode. 411 /// @retval A pointer to the corresponding StaticInst object. 412 //This is defined as inline below. 413 static StaticInstPtr decode(ExtMachInst mach_inst); 414 |
415 /// Return opcode of machine instruction 416 uint32_t getOpcode() { return bits(machInst, 31, 26);} 417 418 /// Return name of machine instruction |
419 std::string getName() { return mnemonic; } 420}; 421 422typedef RefCountingPtr<StaticInstBase> StaticInstBasePtr; 423 424/// Reference-counted pointer to a StaticInst object. 425/// This type should be used instead of "StaticInst *" so that 426/// StaticInst objects can be properly reference-counted. --- 61 unchanged lines hidden --- |