simple_thread.hh (5082:82dd253231c8) | simple_thread.hh (5088:2d5e28510f27) |
---|---|
1/* 2 * Copyright (c) 2001-2006 The Regents of The University of Michigan 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions are 7 * met: redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer; --- 227 unchanged lines hidden (view full) --- 236 uint64_t readIntReg(int reg_idx) 237 { 238 int flatIndex = TheISA::flattenIntIndex(getTC(), reg_idx); 239 return regs.readIntReg(flatIndex); 240 } 241 242 FloatReg readFloatReg(int reg_idx, int width) 243 { | 1/* 2 * Copyright (c) 2001-2006 The Regents of The University of Michigan 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions are 7 * met: redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer; --- 227 unchanged lines hidden (view full) --- 236 uint64_t readIntReg(int reg_idx) 237 { 238 int flatIndex = TheISA::flattenIntIndex(getTC(), reg_idx); 239 return regs.readIntReg(flatIndex); 240 } 241 242 FloatReg readFloatReg(int reg_idx, int width) 243 { |
244 int flatIndex = TheISA::flattenIntIndex(getTC(), reg_idx); | 244 int flatIndex = TheISA::flattenFloatIndex(getTC(), reg_idx); |
245 return regs.readFloatReg(flatIndex, width); 246 } 247 248 FloatReg readFloatReg(int reg_idx) 249 { | 245 return regs.readFloatReg(flatIndex, width); 246 } 247 248 FloatReg readFloatReg(int reg_idx) 249 { |
250 int flatIndex = TheISA::flattenIntIndex(getTC(), reg_idx); | 250 int flatIndex = TheISA::flattenFloatIndex(getTC(), reg_idx); |
251 return regs.readFloatReg(flatIndex); 252 } 253 254 FloatRegBits readFloatRegBits(int reg_idx, int width) 255 { | 251 return regs.readFloatReg(flatIndex); 252 } 253 254 FloatRegBits readFloatRegBits(int reg_idx, int width) 255 { |
256 int flatIndex = TheISA::flattenIntIndex(getTC(), reg_idx); | 256 int flatIndex = TheISA::flattenFloatIndex(getTC(), reg_idx); |
257 return regs.readFloatRegBits(flatIndex, width); 258 } 259 260 FloatRegBits readFloatRegBits(int reg_idx) 261 { | 257 return regs.readFloatRegBits(flatIndex, width); 258 } 259 260 FloatRegBits readFloatRegBits(int reg_idx) 261 { |
262 int flatIndex = TheISA::flattenIntIndex(getTC(), reg_idx); | 262 int flatIndex = TheISA::flattenFloatIndex(getTC(), reg_idx); |
263 return regs.readFloatRegBits(flatIndex); 264 } 265 266 void setIntReg(int reg_idx, uint64_t val) 267 { 268 int flatIndex = TheISA::flattenIntIndex(getTC(), reg_idx); 269 regs.setIntReg(flatIndex, val); 270 } 271 272 void setFloatReg(int reg_idx, FloatReg val, int width) 273 { | 263 return regs.readFloatRegBits(flatIndex); 264 } 265 266 void setIntReg(int reg_idx, uint64_t val) 267 { 268 int flatIndex = TheISA::flattenIntIndex(getTC(), reg_idx); 269 regs.setIntReg(flatIndex, val); 270 } 271 272 void setFloatReg(int reg_idx, FloatReg val, int width) 273 { |
274 int flatIndex = TheISA::flattenIntIndex(getTC(), reg_idx); | 274 int flatIndex = TheISA::flattenFloatIndex(getTC(), reg_idx); |
275 regs.setFloatReg(flatIndex, val, width); 276 } 277 278 void setFloatReg(int reg_idx, FloatReg val) 279 { | 275 regs.setFloatReg(flatIndex, val, width); 276 } 277 278 void setFloatReg(int reg_idx, FloatReg val) 279 { |
280 int flatIndex = TheISA::flattenIntIndex(getTC(), reg_idx); | 280 int flatIndex = TheISA::flattenFloatIndex(getTC(), reg_idx); |
281 regs.setFloatReg(flatIndex, val); 282 } 283 284 void setFloatRegBits(int reg_idx, FloatRegBits val, int width) 285 { | 281 regs.setFloatReg(flatIndex, val); 282 } 283 284 void setFloatRegBits(int reg_idx, FloatRegBits val, int width) 285 { |
286 int flatIndex = TheISA::flattenIntIndex(getTC(), reg_idx); | 286 int flatIndex = TheISA::flattenFloatIndex(getTC(), reg_idx); |
287 regs.setFloatRegBits(flatIndex, val, width); 288 } 289 290 void setFloatRegBits(int reg_idx, FloatRegBits val) 291 { | 287 regs.setFloatRegBits(flatIndex, val, width); 288 } 289 290 void setFloatRegBits(int reg_idx, FloatRegBits val) 291 { |
292 int flatIndex = TheISA::flattenIntIndex(getTC(), reg_idx); | 292 int flatIndex = TheISA::flattenFloatIndex(getTC(), reg_idx); |
293 regs.setFloatRegBits(flatIndex, val); 294 } 295 296 uint64_t readPC() 297 { 298 return regs.readPC(); 299 } 300 --- 113 unchanged lines hidden --- | 293 regs.setFloatRegBits(flatIndex, val); 294 } 295 296 uint64_t readPC() 297 { 298 return regs.readPC(); 299 } 300 --- 113 unchanged lines hidden --- |