View Full Version : Why a higher p4 cpu clock runs slower than Athlon......?
Overclockers
09-02-01, 01:37 AM
I was wondering why a higher p4 cpu clock runs slower than Athlon........? does it mean Intel is worse than AMD......? does anybody can tell me why.......?
for example: 1.7gig p4 is slower than 1.4gig Athlon
The P4 is design to have what we call a long pipeline. As each instruction moves through the cpu it is partial executed in steps with each step being a stage in the pipeline. All modern X86 processors are pipelined this way. Anyway, it means several instructions can be in the pipeline at the same time and being worked on with each instruction being at a different stage. Now the P4 has a longer pipeline with more stages in it. It's designed this way on purpose. This way each stage of the pipeline is simpler and does a little bit of work. Since each stage is simplier it can run at higher frequencies. So, this means that the P4 has the potential to run at very high clock speeds. That's why they choose this route. Now, as I said earlier the pipeline is long and has several stages and this means theoretically you can have instructions being worked on at each stage. So, even though the P4 does little at each stage it can be working on many instructions simultaneosuly. So, the longer pipeline makes up for the fact that very little is done at each stage. The problem comes in when there are issues that keep the pipeline from being filled completely. Say for example one instruction depends on the results of another. In that case you may have to stop that instruction and wait for the other insturction to complete execution before sending it on down the pipeline. This creates stalls or what is sometimes referd to as "bubbles in the pipeline". Whenever that happens on the P4 it hurts it's performance more than a shorter pipelined cpu. Another problem can be program branches. Since the processor is executing instructions simultaneosly at each stage of the pipeline sequentially if one of the instructions is a jump or call instruction that branches to a different location when it gets to the end of the pipeline if the conditions are met for the branch it can mean that all the other instructions behind it that are in the pipeline being worked on are useless and the processor has to just through them away and branch to the location specified by the branch instruction and start all over again filling the pipeline. Fortunately though there is something that can help this. It's called branch prediction and it means that the CPU can look at branch instructions when they first enter the pipeline to try and predict whether they will be taken or not. Some branches are easy to predict. Unconditional branches will always be taken. Others are less easy to predict. Anyway, modern cpus have ways of trying to predict which way a conditional branch will go. One way of doing this is by keeping a table of which way the same instruction went last time if that instruction has been executed before. Often times a branch is part of a loop and will go a certain way many many times and will only go the other way once in a while. In that case the CPU can kinda predict which way it's gonna go and be right most of the time. Anyway, if the CPU can predict which way a branch will go then it will load the instruction at the location specified by the branch into the pipeline right behind the branch and the pipeline will stay filled and the code will be executed faster. Anyway, it all comes down to the actual code that the CPU is executing. Some applications have losts of branching that is not always so predictable. This type of code is gonna be slower on the P4 and also on other CPUs as well, because as I said befoer all modern CPUs use these techniques to a certain degree. It's just that the P4 takes a much bigger penalty when this happens because it's pipeline is so long. Now there will always be some sequences of code that will cause stalls or bubles in the pipeline and also missed branch prediction. However, with planning and forethought the programmer can write his code in such a way to order the instructions so that these stalls in the pipeline and missed branch prediction can be minimized and the code will run much faster. John Carmmack is a genious when it comes to this. You'll notice that Quake 3 runs very fast on the P4. This is no conincidence. Also note that Carmmack wrote Quake 3 long before the P4 was even heard of and there is no SSE2 or even SSE in Quake 3. It's the fact that his code is so effective optimised for pipelining and the instructions so well ordered that makes it perform so well with the P4. Many programmers aren't that well skilled. Also, many programmers write their code in higher level languages like C++ and never deal with it at the lower level. However, Intel has the answer for this. They have new compilers in the works that will genrate code that is optimised to keep the pipeline efficently filled and help minimize stalls and missed branch prediction. It will just take awhile for these optimisations to make to all the software out there, but I believe it will eventually happen. One reason I believe it will happens is because at least 70% of all x86 CPUs sold are Intel CPUs and that isn't gonna change anytime soon. Since Intel is obviously commited to making the P4 successfull, it makes sense for developers to optimise there code in this way. Another thing to keep in mind is that these optimisations don't hurt performance on AMD processors. In fact sometimes even the AMD chips will show a signifact performance improvement with this optimisation. After all, remember what I said before all modern CPUs use pipelining. It's just that the P4 will show a much more susbstantial increase because it's taking big hits when the code doesn't flow through the pipeline efficently. So, you see there is no incentive for developers to mot optimise there code this way.
Another thing that is gonna help the P4 in the future is it's ability to clock higher. remember I said they designed it this way so it would be easier to clock higher. Well, with refinement to the manufacturing process the P4 is gonna eventually be able to clock very high. That's the reason we currently have 2.0Ghz P4s being sold and yet other processors can't clock nearly that high. The gap is only going to widen. The other day Intel demoed a 3.5Ghz P4. They expect to eventually one day get P4 derived processors upto perhaps 10Ghz. We're not going to see those anytime real soon but eventually it will happen. It's not gonna happen with the current K7 core. The K7 core just won't be able to make it that high.
Overclockers
09-02-01, 04:21 AM
wow.......what a surprise...!!!
u really gave me a satisfaction.......
good answer and good explanation......
i wonder how long u wrote that answer......:D
thanx so much.......
btw, one of the opinion that makes me head ache is someone said shuttle AT30 for P4 isn't overclockable........is this true....?
because i really want to speed up my cpu at higher speed.
i have p4 1.3gig with shuttle mobo.
highest regards for answer.
:mad: :mad: :mad:
dozier768
09-02-01, 05:52 AM
also the p4 only does 6 operations per clock cycle and the t-bird does 9 this is the main reason it is more clockable also i dont see the p4 hitting even 3 ghz let alone 10 but this is just my opinion
JetMech
09-02-01, 06:52 AM
The biggest boon I see to the P4 is the basic nature of the current form and all the potential inhancements (.13 micron process, 512 on board cache and if it stays around as long as the p6 core possible a .10 or smaller process allowing even more cache). This would definitely get it near 10ghz.
basically intel designed a mhz monster, a chip that could clock high regardless of the bad performance at such a speed. It's memory bandwidth is it's only saving grace and sse2 once that comes into operation. Also remember a 2ghz p4 only has a 1ghz fpu/sse unit. Hopefully they will fix things in northwood.
SP is it ok if i take your explanation and save it in a word document on my desktop and give it to everyone who doesnt understand why amd can smack intel around with lower clock speeds?your reply was just that good :)
stompah
09-02-01, 01:25 PM
Originally posted by touser
SP is it ok if i take your explanation and save it in a word document on my desktop and give it to everyone who doesnt understand why amd can smack intel around with lower clock speeds?your reply was just that good :)
A locked thread/stickied thread should be made in both intel and amd forums. Just so everybody knows ;)
Kingslayer
09-02-01, 08:03 PM
And here I just thought it was because the programs they use to bench the P4 isn't supported by it.....
Originally posted by touser
SP is it ok if i take your explanation and save it in a word document on my desktop and give it to everyone who doesnt understand why amd can smack intel around with lower clock speeds?your reply was just that good :)
Yeah I know of a computer blabbermouth who's on tv weekly who bashes AMD who I'd love to send a copy to also. May I?
Overclockers
09-03-01, 12:38 AM
if intel know they p4 cpu will hasn't been supported by many programs now, why did they introduce it so early......? was it a marketing error or.......?:confused:
No it's a marketing coup!
Techie:"The Athalon is better even though it's slower."
Average person:"The Athalon is slower?"
Techie:"Yes but it's better!"
Average person:"So it's slower."
Techie:"Yes it's slower but it's better too!"
Average person:"Right, it's slower, I understand now."
Techie:"Are you listening to me? I said it's also better!"
Average person:"Right, slower. Well thanks, that's all I needed to know! I'm gonna go buy a P4 now, because we all know that faster must mean better!"
Overclockers
09-03-01, 12:56 AM
kekekeekekek........good job......well done!!!:D :D :D
i must say one thing, the only reason i bought the P4 was because i had the money, and for the higher memory bandwidth, thats it..i even tried to get an athlon first i tried for 4 months to get an asus A7M266 board from anywhere! nobody had it! i finally found an online shop and they tried to scam me, so i finally said (*^% this and bought a p4..i must say however i am happy with the overall performance of the p4 for what I do :)
Originally posted by eobard
No it's a marketing coup!
Techie:"The Athalon is better even though it's slower."
Average person:"The Athalon is slower?"
Techie:"Yes but it's better!"
Average person:"So it's slower."
Techie:"Yes it's slower but it's better too!"
Average person:"Right, it's slower, I understand now."
Techie:"Are you listening to me? I said it's also better!"
Average person:"Right, slower. Well thanks, that's all I needed to know! I'm gonna go buy a P4 now, because we all know that faster must mean better!"
more like
Techie:"The Athalon is better even though it's slower."
Average person: "whats an athlon, I'll just get a p4 cos I want to use the internet and play games"
vBulletin® v3.8.7, Copyright ©2000-2012, vBulletin Solutions, Inc.