util.isa (8829:d21889bface6) | util.isa (10196:be0e1724eb39) |
---|---|
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 --- 116 unchanged lines hidden (view full) --- 125 } 126 127 return response.str(); 128 } 129}}; 130 131// This template provides the execute functions for a load 132def template LoadExecute {{ | 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 --- 116 unchanged lines hidden (view full) --- 125 } 126 127 return response.str(); 128 } 129}}; 130 131// This template provides the execute functions for a load 132def template LoadExecute {{ |
133 Fault %(class_name)s::execute(%(CPU_exec_context)s *xc, | 133 Fault %(class_name)s::execute(CPU_EXEC_CONTEXT *xc, |
134 Trace::InstRecord *traceData) const 135 { 136 Fault fault = NoFault; 137 Addr EA; 138 %(fp_enable_check)s; 139 %(op_decl)s; 140 %(op_rd)s; 141 %(ea_code)s; --- 11 unchanged lines hidden (view full) --- 153 %(op_wb)s; 154 } 155 156 return fault; 157 } 158}}; 159 160def template LoadInitiateAcc {{ | 134 Trace::InstRecord *traceData) const 135 { 136 Fault fault = NoFault; 137 Addr EA; 138 %(fp_enable_check)s; 139 %(op_decl)s; 140 %(op_rd)s; 141 %(ea_code)s; --- 11 unchanged lines hidden (view full) --- 153 %(op_wb)s; 154 } 155 156 return fault; 157 } 158}}; 159 160def template LoadInitiateAcc {{ |
161 Fault %(class_name)s::initiateAcc(%(CPU_exec_context)s * xc, | 161 Fault %(class_name)s::initiateAcc(CPU_EXEC_CONTEXT * xc, |
162 Trace::InstRecord * traceData) const 163 { 164 Fault fault = NoFault; 165 Addr EA; 166 %(fp_enable_check)s; 167 %(op_decl)s; 168 %(op_rd)s; 169 %(ea_code)s; 170 DPRINTF(Sparc, "%s: The address is 0x%x\n", mnemonic, EA); 171 %(fault_check)s; 172 if (fault == NoFault) { 173 %(EA_trunc)s 174 fault = readMemTiming(xc, traceData, EA, Mem, %(asi_val)s); 175 } 176 return fault; 177 } 178}}; 179 180def template LoadCompleteAcc {{ | 162 Trace::InstRecord * traceData) const 163 { 164 Fault fault = NoFault; 165 Addr EA; 166 %(fp_enable_check)s; 167 %(op_decl)s; 168 %(op_rd)s; 169 %(ea_code)s; 170 DPRINTF(Sparc, "%s: The address is 0x%x\n", mnemonic, EA); 171 %(fault_check)s; 172 if (fault == NoFault) { 173 %(EA_trunc)s 174 fault = readMemTiming(xc, traceData, EA, Mem, %(asi_val)s); 175 } 176 return fault; 177 } 178}}; 179 180def template LoadCompleteAcc {{ |
181 Fault %(class_name)s::completeAcc(PacketPtr pkt, %(CPU_exec_context)s * xc, | 181 Fault %(class_name)s::completeAcc(PacketPtr pkt, CPU_EXEC_CONTEXT * xc, |
182 Trace::InstRecord * traceData) const 183 { 184 Fault fault = NoFault; 185 %(op_decl)s; 186 %(op_rd)s; 187 getMem(pkt, Mem, traceData); 188 %(code)s; 189 if (fault == NoFault) { 190 %(op_wb)s; 191 } 192 return fault; 193 } 194}}; 195 196// This template provides the execute functions for a store 197def template StoreExecute {{ | 182 Trace::InstRecord * traceData) const 183 { 184 Fault fault = NoFault; 185 %(op_decl)s; 186 %(op_rd)s; 187 getMem(pkt, Mem, traceData); 188 %(code)s; 189 if (fault == NoFault) { 190 %(op_wb)s; 191 } 192 return fault; 193 } 194}}; 195 196// This template provides the execute functions for a store 197def template StoreExecute {{ |
198 Fault %(class_name)s::execute(%(CPU_exec_context)s *xc, | 198 Fault %(class_name)s::execute(CPU_EXEC_CONTEXT *xc, |
199 Trace::InstRecord *traceData) const 200 { 201 Fault fault = NoFault; 202 // This is to support the conditional store in cas instructions. 203 // It should be optomized out in all the others 204 bool storeCond = true; 205 Addr EA; 206 %(fp_enable_check)s; --- 14 unchanged lines hidden (view full) --- 221 %(op_wb)s; 222 } 223 224 return fault; 225 } 226}}; 227 228def template StoreInitiateAcc {{ | 199 Trace::InstRecord *traceData) const 200 { 201 Fault fault = NoFault; 202 // This is to support the conditional store in cas instructions. 203 // It should be optomized out in all the others 204 bool storeCond = true; 205 Addr EA; 206 %(fp_enable_check)s; --- 14 unchanged lines hidden (view full) --- 221 %(op_wb)s; 222 } 223 224 return fault; 225 } 226}}; 227 228def template StoreInitiateAcc {{ |
229 Fault %(class_name)s::initiateAcc(%(CPU_exec_context)s * xc, | 229 Fault %(class_name)s::initiateAcc(CPU_EXEC_CONTEXT * xc, |
230 Trace::InstRecord * traceData) const 231 { 232 Fault fault = NoFault; 233 bool storeCond = true; 234 Addr EA; 235 %(fp_enable_check)s; 236 %(op_decl)s; 237 --- 8 unchanged lines hidden (view full) --- 246 %(EA_trunc)s 247 fault = writeMemTiming(xc, traceData, Mem, EA, %(asi_val)s, 0); 248 } 249 return fault; 250 } 251}}; 252 253def template StoreCompleteAcc {{ | 230 Trace::InstRecord * traceData) const 231 { 232 Fault fault = NoFault; 233 bool storeCond = true; 234 Addr EA; 235 %(fp_enable_check)s; 236 %(op_decl)s; 237 --- 8 unchanged lines hidden (view full) --- 246 %(EA_trunc)s 247 fault = writeMemTiming(xc, traceData, Mem, EA, %(asi_val)s, 0); 248 } 249 return fault; 250 } 251}}; 252 253def template StoreCompleteAcc {{ |
254 Fault %(class_name)s::completeAcc(PacketPtr, %(CPU_exec_context)s * xc, | 254 Fault %(class_name)s::completeAcc(PacketPtr, CPU_EXEC_CONTEXT * xc, |
255 Trace::InstRecord * traceData) const 256 { 257 return NoFault; 258 } 259}}; 260 261def template EACompExecute {{ 262 Fault | 255 Trace::InstRecord * traceData) const 256 { 257 return NoFault; 258 } 259}}; 260 261def template EACompExecute {{ 262 Fault |
263 %(class_name)s::eaComp(%(CPU_exec_context)s *xc, | 263 %(class_name)s::eaComp(CPU_EXEC_CONTEXT *xc, |
264 Trace::InstRecord *traceData) const 265 { 266 Addr EA; 267 Fault fault = NoFault; 268 %(op_decl)s; 269 %(op_rd)s; 270 %(ea_code)s; 271 %(fault_check)s; --- 95 unchanged lines hidden --- | 264 Trace::InstRecord *traceData) const 265 { 266 Addr EA; 267 Fault fault = NoFault; 268 %(op_decl)s; 269 %(op_rd)s; 270 %(ea_code)s; 271 %(fault_check)s; --- 95 unchanged lines hidden --- |