Re: [m5-dev] [PATCH 2 of 5] Fix Branch Prediction for MIPS. Namely, i dont see the reason for updating the branch history on anything that happens in decode. this should happen only in commit, right?

2009-04-18 Thread nathan binkert
Im not sure what you did with your patches, Korey, but a literal '\n' is not the same as an actual newline :-). I'm confused. What are you referring to Steve? ___ m5-dev mailing list m5-dev@m5sim.org http://m5sim.org/mailman/listinfo/m5-dev

Re: [m5-dev] [PATCH 2 of 5] Fix Branch Prediction for MIPS. Namely, i dont see the reason for updating the branch history on anything that happens in decode. this should happen only in commit, right?

2009-04-18 Thread Korey Sewell
Yea, I thought it would do the trick...obviously not! I was adding the message as : hg qrefresh -m \n So I guess I have to commit in a real text editor to get the newline to show. On Sat, Apr 18, 2009 at 12:16 PM, Steve Reinhardt ste...@gmail.com wrote: Im not sure what you did with

Re: [m5-dev] [PATCH 2 of 5] Fix Branch Prediction for MIPS. Namely, i dont see the reason for updating the branch history on anything that happens in decode. this should happen only in commit, right?

2009-04-18 Thread nathan binkert
You can actually put a real newline in there. If you're in the middle of a quoted string, the shell won't try to execute the statement. Instead, it will allow you to finish the string. So I regularly will do something like: hg qref -m foo: this is a foo bar more comments even more On Sat, Apr

Re: [m5-dev] [PATCH 2 of 5] Fix Branch Prediction for MIPS. Namely, i dont see the reason for updating the branch history on anything that happens in decode. this should happen only in commit, right?

2009-04-18 Thread nathan binkert
Oh, and don't forget that you should be saying hg outgoing to make sure that you know what you're pushing before you say hg push. You would have noticed the error if you had done so. Nate On Sat, Apr 18, 2009 at 9:51 AM, nathan binkert n...@binkert.org wrote: You can actually put a real

Re: [m5-dev] [PATCH 2 of 5] Fix Branch Prediction for MIPS. Namely, i dont see the reason for updating the branch history on anything that happens in decode. this should happen only in commit, right?

2009-04-17 Thread Korey Sewell
OK So I finally figured out what's wrong here and admittedly I'm a bit apprehensive of the universal (all ISA) fix will be but we'll see. So let me explain the situation from the top: (1) In the Decode of O3, an unconditional pc-relative branch is resolved and the prediciton history table is

Re: [m5-dev] [PATCH 2 of 5] Fix Branch Prediction for MIPS. Namely, i dont see the reason for updating the branch history on anything that happens in decode. this should happen only in commit, right?

2009-04-17 Thread Steve Reinhardt
Thanks for digging into this in more detail, Korey. It sounds to me like maybe the problem is that MIPS is setting predPC to the branch target, when (to account for the delay slot) it ought to be leaving predPC as PC+4 and setting predNPC to be the branch target. That way if the prediction turns

Re: [m5-dev] [PATCH 2 of 5] Fix Branch Prediction for MIPS. Namely, i dont see the reason for updating the branch history on anything that happens in decode. this should happen only in commit, right?

2009-04-16 Thread Gabriel Michael Black
Also, why do you change inst-readNextNPC() to inst-readNextPC() in iew_impl.hh? Aren't you going to then print the same value twice? Well, I'm trying to fix error'd DPRINT statements here. In the DPRINT, it says NPC, but it's printing out the NNPC which was confusing to me. So maybe the

[m5-dev] [PATCH 2 of 5] Fix Branch Prediction for MIPS. Namely, i dont see the reason for updating the branch history on anything that happens in decode. this should happen only in commit, right?

2009-04-15 Thread Korey Sewell
# HG changeset patch # User Korey Sewell ksew...@umich.edu # Date 1239850525 14400 # Node ID ce539a58327b78b049f8af0bf8a00737f2b97640 # Parent 7b685fee8773c2fe0bd09ec7abb0a43873aeed92 Fix Branch Prediction for MIPS. Namely, i dont see the reason for updating the branch history on anything that

Re: [m5-dev] [PATCH 2 of 5] Fix Branch Prediction for MIPS. Namely, i dont see the reason for updating the branch history on anything that happens in decode. this should happen only in commit, right?

2009-04-15 Thread Korey Sewell
This is the patch that will prevent me from committing. Basically, the decode stage is finding a mispredicted branch and then deleting information out the branch history table for squashed instructions AND itself. This messes things up for when the actual mispredicted instruction gets to commit

Re: [m5-dev] [PATCH 2 of 5] Fix Branch Prediction for MIPS. Namely, i dont see the reason for updating the branch history on anything that happens in decode. this should happen only in commit, right?

2009-04-15 Thread Steve Reinhardt
I'm confused... this patch looks like it pretty much just inserts a bunch of DPRINTFs (plus the seemingly mistaken inclusion of a whitespace change in mips/isa/decoder.isa). I don't know anything specific about the O3 predictor, but it makes sense that the history is updated speculatively in

Re: [m5-dev] [PATCH 2 of 5] Fix Branch Prediction for MIPS. Namely, i dont see the reason for updating the branch history on anything that happens in decode. this should happen only in commit, right?

2009-04-15 Thread Steve Reinhardt
I see now, I missed that little change buried at the bottom. I recall that condition about unconditional PC-relative branches finding out in decode that their target was mispredicted too. I'm wondering if you're not just hacking around the real problem here... I don't see how this particular

Re: [m5-dev] [PATCH 2 of 5] Fix Branch Prediction for MIPS. Namely, i dont see the reason for updating the branch history on anything that happens in decode. this should happen only in commit, right?

2009-04-15 Thread Korey Sewell
Yea, I'm worried about some more deep-seeded problem here too...In the interim, though, at least we know the main problem is with the branch prediction (since I fixed the TLB/Syscall stuff in other patches). Like I mentioned earlier, I did the same *hack:* for Alpha and Sparc and both of the

Re: [m5-dev] [PATCH 2 of 5] Fix Branch Prediction for MIPS. Namely, i dont see the reason for updating the branch history on anything that happens in decode. this should happen only in commit, right?

2009-04-15 Thread Gabe Black
My question is why does the branch predictor matter as far as functional correctness? If it was wrong 100% of the time wouldn't that just make O3 slow? Also, why do you change inst-readNextNPC() to inst-readNextPC() in iew_impl.hh? Aren't you going to then print the same value twice? Gabe Korey