News for hackers. Stuff that matters.
Re:Why is this C++ code faster than my hand-written assembly... by spc476 on Tuesday August 22, 2017 @03:00PM (#15075393)
The x86-64 bit isn't bad. You get 16 registers (half named, half numbered---historical baggage) and opcodes galore (more than even the VAX architecture). The x86-32 bit is a mixed bag (8 registers, the specialized opcodes may or may not be worth using depending upon which chip you use), but it certainly helps to know the history (the 8086 and 80286) to understand why it's the way it is.

A few weeks ago I tried my hand at optimizing some code using the vector instructions. While I was able to beat clang quite easily using assembly, I just could not beat GCC. That was sobering. There's probably some 1000 page tome I have to read to understand where I messed up in optimizing.

Re:Why is this C++ code faster than my hand-written assembly... by vram22 on Tuesday August 22, 2017 @04:54PM (#15076299)
Is the x86 family the only processor family that had the segment:offset thing?
Re:Why is this C++ code faster than my hand-written assembly... by __s on Tuesday August 22, 2017 @06:30PM (#15076931)