Deleted Added
sdiff udiff text old ( 3801:5ea378e2bccd ) new ( 3965:b4cab77371ed )
full compact
1/*
2 * Copyright (c) 2004-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;

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

204 Result instResult;
205
206 /** Records changes to result? */
207 bool recordResult;
208
209 /** PC of this instruction. */
210 Addr PC;
211
212 /** Next non-speculative PC. It is not filled in at fetch, but rather
213 * once the target of the branch is truly known (either decode or
214 * execute).
215 */
216 Addr nextPC;
217
218 /** Next non-speculative NPC. Target PC for Mips or Sparc. */
219 Addr nextNPC;
220
221 /** Predicted next PC. */
222 Addr predPC;
223
224 /** Predicted next NPC. */
225 Addr predNPC;
226
227 /** If this is a branch that was predicted taken */
228 bool predTaken;
229
230 /** Count of total number of dynamic instructions. */
231 static int instcount;
232
233#ifdef DEBUG
234 void dumpSNList();
235#endif
236
237 /** Whether or not the source register is ready.

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

385 /** Returns the next PC. This could be the speculative next PC if it is
386 * called prior to the actual branch target being calculated.
387 */
388 Addr readNextPC() { return nextPC; }
389
390 /** Returns the next NPC. This could be the speculative next NPC if it is
391 * called prior to the actual branch target being calculated.
392 */
393 Addr readNextNPC() { return nextNPC; }
394
395 /** Set the predicted target of this current instruction. */
396 void setPredTarg(Addr predicted_PC, Addr predicted_NPC)
397 {
398 predPC = predicted_PC;
399 predNPC = predicted_NPC;
400 }
401

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

414 void setPredTaken(bool predicted_taken)
415 {
416 predTaken = predicted_taken;
417 }
418
419 /** Returns whether the instruction mispredicted. */
420 bool mispredicted()
421 {
422 return predPC != nextPC || predNPC != nextNPC;
423 }
424
425 //
426 // Instruction types. Forward checks to StaticInst object.
427 //
428 bool isNop() const { return staticInst->isNop(); }
429 bool isMemRef() const { return staticInst->isMemRef(); }
430 bool isLoad() const { return staticInst->isLoad(); }

--- 436 unchanged lines hidden ---