4 ms·
Use x64 - the calling convention is simpler and you get more registers. Avoid the exotic instructions.
by MichaelBurge 10y ago
Use x64 - the calling convention is simpler and you get more registers. Avoid the exotic instructions.
- spc476 10y agoAnd just accept that half the registers are named (rax, rbx) and the other half are numbered (r8, r9).
- chubot 10y agoCan anyone recommend the best resource for learning x64 then? I did computer architecture and assembly language 15+ years ago in school but haven't really needed to touch assembly language as a professional programmer. So I know the basic idea of registers and addressing modes and pipelines and stuff, but nothing specific to any architecture. My goal is basically to be able to write faster C and C++ programs and analyze constructs like the cost of things like smart pointers, virtual dispatch, templates, etc.
- lorenzhs 10y agoI'd be very interested in such a resource as well. At the moment I'm just staring at the output of 'objdump -S', trying to make sense of things and find what's different between two versions. For smaller things, Matt Godbolt's compiler explorer is very helpful as well. But I'm still having trouble figuring out what exactly is happening and why some things are required, etc.