  Steve I'm a PC, so shut up Consultant join:2001-03-10 Yorba Linda, CA
| reply to TSI Gabe Re: For those wondering "Why Playstation 3s?"
said by TSI Gabe :No Actually removing a printf simply displaying the value being calculated completely removed the md5 function from the code. The compiler did what it was supposed to do: if you were calling a function that had no side effects, it knew that it could eliminate the call without having any effect on correct operation. It was right.
Benchmarking is a known science; calling your operation in a way that insists on a side effect (as I'm sure you found) lets you get the effect you want.
Steve -- Stephen J. Friedl | Unix Wizard | Microsoft Security MVP | Orange County, California USA | my web site |
|
  TSI Gabe Premium,VIP join:2007-01-03 Chatham, ON | reply to Steve No Actually removing a printf simply displaying the value being calculated completely removed the md5 function from the code. |
|
  Steve I'm a PC, so shut up Consultant join:2001-03-10 Yorba Linda, CA
| reply to TSI Gabe said by TSI Gabe :That was the C compiler optimizing my code into doing nothing quite literally. Sometimes those C optimizations don't really help... It's far more likely that your optimizer found a bug in your code than you found a bug in the optimizer.
The problem with compilers is that they do exactly what you ask them too bad women and children won't follow that example 
Steve -- Stephen J. Friedl | Unix Wizard | Microsoft Security MVP | Orange County, California USA | my web site |
|
  TSI Gabe Premium,VIP join:2007-01-03 Chatham, ON | reply to Steve That was the C compiler optimizing my code into doing nothing quite literally. Sometimes those C optimizations don't really help... |
|
 beaups
join:2003-08-11 Hilliard, OH | reply to Steve lol I was just wondering the same thing |
|
  Steve I'm a PC, so shut up Consultant join:2001-03-10 Yorba Linda, CA
| reply to TSI Gabe said by TSI Gabe :Yeah I've coded an MD5 algo myself for the PS3 and it does 80 million hashes per second. What ever happened to 30 billion hashes per second? -- Stephen J. Friedl | Unix Wizard | Microsoft Security MVP | Orange County, California USA | my web site |
|
  TSI Gabe Premium,VIP join:2007-01-03 Chatham, ON | reply to espaeth Yeah I've coded an MD5 algo myself for the PS3 and it does 80 million hashes per second.
This may not look like a lot, but its just about as much as a very expensive Xeon server so your bang for the buck is quite real. |
|