specop.isa (4679:0b39fa8f5eb8) | specop.isa (4696:459853ed322c) |
---|---|
1// Copyright (c) 2007 The Hewlett-Packard Development Company 2// All rights reserved. 3// 4// Redistribution and use of this software in source and binary forms, 5// with or without modification, are permitted provided that the 6// following conditions are met: 7// 8// The software must be used only for Non-Commercial Use which means any --- 61 unchanged lines hidden (view full) --- 70 MicroFault(ExtMachInst _machInst, const char * instMnem, 71 bool isMicro, bool isDelayed, bool isFirst, bool isLast, 72 Fault _fault); 73 74 MicroFault(ExtMachInst _machInst, const char * instMnem, 75 Fault _fault); 76 77 %(BasicExecDeclare)s | 1// Copyright (c) 2007 The Hewlett-Packard Development Company 2// All rights reserved. 3// 4// Redistribution and use of this software in source and binary forms, 5// with or without modification, are permitted provided that the 6// following conditions are met: 7// 8// The software must be used only for Non-Commercial Use which means any --- 61 unchanged lines hidden (view full) --- 70 MicroFault(ExtMachInst _machInst, const char * instMnem, 71 bool isMicro, bool isDelayed, bool isFirst, bool isLast, 72 Fault _fault); 73 74 MicroFault(ExtMachInst _machInst, const char * instMnem, 75 Fault _fault); 76 77 %(BasicExecDeclare)s |
78 79 std::string generateDisassembly(Addr pc, 80 const SymbolTable *symtab) const; |
|
78 }; 79}}; 80 81output decoder {{ 82 Fault MicroFault::execute(%(CPU_exec_context)s *xc, 83 Trace::InstRecord *traceData) const 84 { 85 //Return the fault we were constructed with --- 15 unchanged lines hidden (view full) --- 101 Fault _fault) : 102 X86MicroopBase(machInst, "fault", instMnem, 103 isMicro, isDelayed, isFirst, isLast, No_OpClass), 104 fault(_fault) 105 { 106 } 107}}; 108 | 81 }; 82}}; 83 84output decoder {{ 85 Fault MicroFault::execute(%(CPU_exec_context)s *xc, 86 Trace::InstRecord *traceData) const 87 { 88 //Return the fault we were constructed with --- 15 unchanged lines hidden (view full) --- 104 Fault _fault) : 105 X86MicroopBase(machInst, "fault", instMnem, 106 isMicro, isDelayed, isFirst, isLast, No_OpClass), 107 fault(_fault) 108 { 109 } 110}}; 111 |
112output decoder {{ 113 std::string MicroFault::generateDisassembly(Addr pc, 114 const SymbolTable *symtab) const 115 { 116 std::stringstream response; 117 118 printMnemonic(response, instMnem, mnemonic); 119 if(fault) 120 response << fault->name(); 121 else 122 response << "No Fault"; 123 124 return response.str(); 125 } 126}}; 127 |
|
109let {{ 110 class Fault(X86Microop): 111 def __init__(self, fault): 112 self.fault = fault 113 114 def getAllocator(self, *microFlags): 115 allocator = '''new MicroFault(machInst, mnemonic 116 %(flags)s, %(fault)s)''' % { 117 "flags" : self.microFlagsText(microFlags), 118 "fault" : self.fault} 119 return allocator 120 microopClasses["fault"] = Fault 121}}; | 128let {{ 129 class Fault(X86Microop): 130 def __init__(self, fault): 131 self.fault = fault 132 133 def getAllocator(self, *microFlags): 134 allocator = '''new MicroFault(machInst, mnemonic 135 %(flags)s, %(fault)s)''' % { 136 "flags" : self.microFlagsText(microFlags), 137 "fault" : self.fault} 138 return allocator 139 microopClasses["fault"] = Fault 140}}; |