basic.isa (4011:e6899d7ca5b1) | basic.isa (4362:95e5f28ce484) |
---|---|
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 --- 83 unchanged lines hidden (view full) --- 92 93// Basic decode template, passing mnemonic in as string arg to constructor. 94def template BasicDecodeWithMnemonic {{ 95 return new %(class_name)s("%(mnemonic)s", machInst); 96}}; 97 98// The most basic instruction format... used only for a few misc. insts 99def format BasicOperate(code, *flags) {{ | 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 --- 83 unchanged lines hidden (view full) --- 92 93// Basic decode template, passing mnemonic in as string arg to constructor. 94def template BasicDecodeWithMnemonic {{ 95 return new %(class_name)s("%(mnemonic)s", machInst); 96}}; 97 98// The most basic instruction format... used only for a few misc. insts 99def format BasicOperate(code, *flags) {{ |
100 code = filterDoubles(code) |
|
100 iop = InstObjParams(name, Name, 'SparcStaticInst', code, flags) 101 header_output = BasicDeclare.subst(iop) 102 decoder_output = BasicConstructor.subst(iop) 103 decode_block = BasicDecode.subst(iop) 104 exec_output = BasicExecute.subst(iop) 105}}; 106 107def format FpBasic(code, *flags) {{ --- 27 unchanged lines hidden (view full) --- 135 136 fp_code += """ 137#if defined(__sun) || defined (__OpenBSD__) 138 fpsetround(oldrnd); 139#else 140 fesetround(oldrnd); 141#endif 142""" | 101 iop = InstObjParams(name, Name, 'SparcStaticInst', code, flags) 102 header_output = BasicDeclare.subst(iop) 103 decoder_output = BasicConstructor.subst(iop) 104 decode_block = BasicDecode.subst(iop) 105 exec_output = BasicExecute.subst(iop) 106}}; 107 108def format FpBasic(code, *flags) {{ --- 27 unchanged lines hidden (view full) --- 136 137 fp_code += """ 138#if defined(__sun) || defined (__OpenBSD__) 139 fpsetround(oldrnd); 140#else 141 fesetround(oldrnd); 142#endif 143""" |
144 fp_code = filterDoubles(fp_code) |
|
143 iop = InstObjParams(name, Name, 'SparcStaticInst', fp_code, flags) 144 header_output = BasicDeclare.subst(iop) 145 decoder_output = BasicConstructor.subst(iop) 146 decode_block = BasicDecode.subst(iop) 147 exec_output = BasicExecute.subst(iop) 148}}; | 145 iop = InstObjParams(name, Name, 'SparcStaticInst', fp_code, flags) 146 header_output = BasicDeclare.subst(iop) 147 decoder_output = BasicConstructor.subst(iop) 148 decode_block = BasicDecode.subst(iop) 149 exec_output = BasicExecute.subst(iop) 150}}; |