Hacker Read top | best | new | newcomments | leaders | about | bookmarklet login

I think that AMD Developer Guides & Manuals [1] are very good resources for x86_64 System Programming (better than Intel Manuals). They are better explained and focus on x86_64 arch.

[1]: http://developer.amd.com/resources/documentation-articles/de...



sort by: page size:

The official manuals from intel are pretty good, better for reference but still good:

http://www.intel.com/content/www/us/en/processors/architectu...


I would highly recommend AMD's developer manual. It's a lot more written for actual reading rather than a pure tech manual with super thick language like Intel's is.

I would also recommend NASM's guide for syntax and such. https://www.nasm.us/xdoc/2.13.03rc1/html/nasmdoc0.html


I second the Intel reference manuals - they've been extremely useful on multiple occasions and have been great at helping me understand the x86 processors better.

Here is the AMD64 reference manual https://www.amd.com/system/files/TechDocs/40332.pdf

The stuff you will need most is in Volume 3.


One resource I found myself consulting over and over again was the Intel Architecture Software Development manuals (https://software.intel.com/en-us/articles/intel-sdm). They're huge and obviously a bit dry, but they had about 90% of what I needed to know about x86 memory architecture and interrupts.

I included some other resources I consulted in the README. The OSDev wiki (http://wiki.osdev.org/Main_Page) is also good, although I found some of it to be dated or incorrect.

Good luck on developing your OS. Even though I'm not finished, it's been an extraordinarily valuable and educational process.


Some free quality resources, ready to use:

- Intel CPU programming guide https://www.intel.com/content/dam/www/public/us/en/documents...

- Calling conventions https://en.wikipedia.org/wiki/X86_calling_conventions https://en.wikibooks.org/wiki/X86_Disassembly/Calling_Conven...

- Web compiler output viewer https://godbolt.org/

- Operation code (opcode) reference http://ref.x86asm.net/

- Disassembler/debugger https://github.com/eteran/edb-debugger, https://x64dbg.com

- Disassembler/Reverse engineering tools http://hte.sourceforge.net/ https://github.com/radareorg/cutter

And this: https://github.com/codilime/veles (binary analysis tool)


I program AMD chips in game consoles so I use a different set of manuals but AMD has a lot of docs available to public at http://developer.amd.com/resources/documentation-articles/de...

At glance there is a lot of legacy stuff so I'd look at anything related to GCN, Sea Islands and Southern Islands. Evergreen, R600-800 etc are legacy VLIW ISA as far as I know.


This page contains links to AMD's :

BIOS and Kernel Developer’s Guide (BKDG)

Note that here are multiple versions of this document -- that's because there's a specific one to each AMD CPU Family...

Opinion: This manual is amazingly, amazingly detailed and highly, highly recommended for any current or future OS Writer or OS Student, with respect to AMD CPU's...


Aside from what has already been suggested, you could consider reading selected chapters of Intel's programmer manual. I personally read through the whole thing once (well, skimmed some parts).

From my experience, Intel's x86 manual is better and easier to read than AMD's. It's a free download.


I learned from Agner's guides, the Intel and AMD optimization manuals and experimentation.

It didn't exist in its current form whenn I started, but the x86 tag wiki is a great source for x86 specific stuff:

https://stackoverflow.com/tags/x86/info

I focus on x86 but I would say 75% of the knowledge is transferable to other architectures. 25% is weird x86 stuff that you aren't likely to find anywhere else.


For x86 specifically, Agner Fog's manual, the Intel and AMD optimization manuals, the SO x86 tag wiki [1].

[1] https://stackoverflow.com/tags/x86/info


There's a lot of information out there, but what's most useful depends on your goals and current level of knowledge.

If you haven't read them yet, Agner Fog's guides are an excellent place to start: http://agner.org/optimize/.

Intel's Software Development Manuals are enormous, but contain a lot of great information: https://software.intel.com/en-us/articles/intel-sdm.

Their "Software Optimization Reference Manual" might be the best place to jump in: https://software.intel.com/sites/default/files/managed/9e/bc....


Intel® 64 and IA-32 Architectures Software Developer Manuals

https://www.intel.com/content/www/us/en/developer/articles/t...

Before the internet, Intel used to distribute these manuals in hard-copy for free. One just had to drop by your local Intel sales office to pick up a copy. A good solid foot of shelf-space.

These manuals used to be so much easier to read back in the 486/Pentium era. One could almost build a complete mental model of how a 486 worked, and how to manually optimize code to best effect by avoiding processor stalls.

Since then, intel processors have accumulated an extraordinary amount of cruft, so it becomes much harder to develop a complete mental model. Compilers have also gotten a lot more clever as well, in order to deal with the added complexity of SIMD instruction sets.

For those of us who started with the 8086 Architecture manuals, each generation of processors added additional features which one learned by occasionally revisiting the architecture manuals for new processors.

Coming to the Architecture manuals without having the foundation of previous Architecture manuals as a basis must be a daunting task. But I'm sure there's rich material there anyway.


These are pretty indispensable when it comes to modern x86 assembly: http://www.intel.com/products/processor/manuals/

The equivalent manuals are available from Intel and AMD.

Other optimization awareness resources:

> This series of five manuals describes everything you need to know about optimizing code for x86 and x86-64 family microprocessors, including optimization advices for C++ and assembly language, details about the microarchitecture and instruction timings of most Intel, AMD and VIA processors, and details about different compilers and calling conventions.

> Operating systems covered: DOS, Windows, Linux, BSD, Mac OS X Intel based, 32 and 64 bits.

https://agner.org/optimize/#manuals


Neat. I was unaware of this manual. For the lazy but curious:

https://software.intel.com/content/www/us/en/develop/downloa...

And if you want ALL THE THINGS:

https://software.intel.com/content/www/us/en/develop/article...


One of my favorite technical papers covers the AMD x64 inception -- it's gold if you're into low-level OS internals: https://github.com/tpn/pdfs/blob/master/A%20History%20of%20M...

Sure:

Intel optimization reference manual: http://www.intel.com/content/dam/www/public/us/en/documents/...

Agner Fog's Software optimization resources: http://www.agner.org/optimize/

I don't think it starts making sense until the 5th reading or so :).

next

Legal | privacy