cpuid.isa (7622:b49144029ec8) | cpuid.isa (9038:d7ddf3266d46) |
---|---|
1// Copyright (c) 2008 The Hewlett-Packard Development Company 2// All rights reserved. 3// 4// The license below extends only to copyright in the software and shall 5// not be construed as granting a license to any other intellectual 6// property including but not limited to intellectual property relating 7// to a hardware implementation of the functionality of the software 8// licensed hereunder. You may use the software subject to the license --- 59 unchanged lines hidden (view full) --- 68}}; 69 70def template CPUIDExecute {{ 71 Fault %(class_name)s::execute(%(CPU_exec_context)s *xc, 72 Trace::InstRecord *traceData) const 73 { 74 // If the CPUID instruction used a valid function number, this will 75 // be set to true. Otherwise, the instruction does nothing. | 1// Copyright (c) 2008 The Hewlett-Packard Development Company 2// All rights reserved. 3// 4// The license below extends only to copyright in the software and shall 5// not be construed as granting a license to any other intellectual 6// property including but not limited to intellectual property relating 7// to a hardware implementation of the functionality of the software 8// licensed hereunder. You may use the software subject to the license --- 59 unchanged lines hidden (view full) --- 68}}; 69 70def template CPUIDExecute {{ 71 Fault %(class_name)s::execute(%(CPU_exec_context)s *xc, 72 Trace::InstRecord *traceData) const 73 { 74 // If the CPUID instruction used a valid function number, this will 75 // be set to true. Otherwise, the instruction does nothing. |
76 bool success; | |
77 %(op_decl)s; 78 %(op_rd)s; 79 %(code)s; | 76 %(op_decl)s; 77 %(op_rd)s; 78 %(code)s; |
80 if (success) { 81 %(op_wb)s; 82 } | 79 %(op_wb)s; |
83 return NoFault; 84 } 85}}; 86 87def format CPUIDInst(code, *opt_flags) {{ 88 iop = InstObjParams(name, Name, 'CPUIDInst', code, opt_flags) 89 header_output = BasicDeclare.subst(iop) 90 decoder_output = BasicConstructor.subst(iop) 91 decode_block = BasicDecode.subst(iop) 92 exec_output = CPUIDExecute.subst(iop) 93}}; 94 | 80 return NoFault; 81 } 82}}; 83 84def format CPUIDInst(code, *opt_flags) {{ 85 iop = InstObjParams(name, Name, 'CPUIDInst', code, opt_flags) 86 header_output = BasicDeclare.subst(iop) 87 decoder_output = BasicConstructor.subst(iop) 88 decode_block = BasicDecode.subst(iop) 89 exec_output = CPUIDExecute.subst(iop) 90}}; 91 |