trap.isa (3792:dae368e56d0e) trap.isa (3995:ef17a5754312)
1// Copyright (c) 2006 The Regents of The University of Michigan
1// Copyright (c) 2006-2007 The Regents of The University of Michigan
2// All rights reserved.
3//
4// Redistribution and use in source and binary forms, with or without
5// modification, are permitted provided that the following conditions are
6// met: redistributions of source code must retain the above copyright
7// notice, this list of conditions and the following disclaimer;
8// redistributions in binary form must reproduce the above copyright
9// notice, this list of conditions and the following disclaimer in the

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

84
85def format Trap(code, *opt_flags) {{
86 iop = InstObjParams(name, Name, 'Trap', code, opt_flags)
87 header_output = BasicDeclare.subst(iop)
88 decoder_output = BasicConstructor.subst(iop)
89 decode_block = BasicDecode.subst(iop)
90 exec_output = TrapExecute.subst(iop)
91}};
2// All rights reserved.
3//
4// Redistribution and use in source and binary forms, with or without
5// modification, are permitted provided that the following conditions are
6// met: redistributions of source code must retain the above copyright
7// notice, this list of conditions and the following disclaimer;
8// redistributions in binary form must reproduce the above copyright
9// notice, this list of conditions and the following disclaimer in the

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

84
85def format Trap(code, *opt_flags) {{
86 iop = InstObjParams(name, Name, 'Trap', code, opt_flags)
87 header_output = BasicDeclare.subst(iop)
88 decoder_output = BasicConstructor.subst(iop)
89 decode_block = BasicDecode.subst(iop)
90 exec_output = TrapExecute.subst(iop)
91}};
92
93output header {{
94 class FpUnimpl : public SparcStaticInst
95 {
96 protected:
97 FpUnimpl(const char *mnem,
98 ExtMachInst _machInst, OpClass __opClass)
99 : SparcStaticInst(mnem, _machInst, __opClass)
100 {
101 }
102
103 std::string generateDisassembly(Addr pc,
104 const SymbolTable *symtab) const
105 {
106 return mnemonic;
107 }
108 };
109}};
110
111def format FpUnimpl(*flags) {{
112 fpunimpl_code = '''
113 Fsr = insertBits(Fsr, 16, 14, 3);
114 fault = new FpExceptionOther;
115 '''
116 iop = InstObjParams(name, Name, 'FpUnimpl', fpunimpl_code, flags)
117 header_output = BasicDeclare.subst(iop)
118 decoder_output = BasicConstructor.subst(iop)
119 decode_block = BasicDecode.subst(iop)
120 exec_output = TrapExecute.subst(iop)
121}};