On Wed, Feb 14, 2007 at 08:18:16AM +0200, Shachar Shemesh wrote: > Just for the record, it is not at all clear that, on modern CPUs, code > you write in machine code (or even Assembly) will, in fact, run faster. > The compiler can be quite good at opimizing your code for machine > language expression, often much better than you would be.
However, a good assembly langunage programer can write code the is "leaner and meaner" than a compiler generates. In practical terms, a good C programmer can often write code that is close, and parallel processing CPUs where the order of instructions is critical a good compiler can outdo an assembly language programmer. I've kept out of that part of CPU design for a long time, I don't know if anything found on a desktop does it. I think the P4, PPC, and current SPARC chips do, but I would not bet on all of them. It's not new technology, Control Data had it in around 1970. Their chief design engineer was Seymor Cray, who later became famous on his own. It also depends upon the complexity of the intruction set. CISC computers are easy to program in assembly language and get better code, RISC chips become harder as many functions can not be done in machine code and have to be combinations of instructions. Then you are dependent upon how good your skill is at combining instructions or that of the author of your macro library. >From my experience good programing technique and logic are far better at producing code effiency than writing in a specific language. I've seen many cases where the order in which you do things effects the preformance more than the languguage they were written in. Geoff. -- Geoffrey S. Mendelson, Jerusalem, Israel [EMAIL PROTECTED] N3OWJ/4X1GM IL Voice: (07)-7424-1667 Fax ONLY: 972-2-648-1443 U.S. Voice: 1-215-821-1838 Visit my 'blog at http://geoffstechno.livejournal.com/ ================================================================= To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]