Author Topic: Architecture? Instruction set?  (Read 3876 times)

Offline Xandaros

  • Jr. Member
  • *
  • Posts: 2
Architecture? Instruction set?
« on: June 04, 2012, 06:33:28 PM »
If I assemble or compile a program on a modern cpu, what architecture do I assemble/compile it for? x86?
Also, can I find a complete instruction set on that architecture? It might differ between the cpus, but what makes it what it is?

I have only been programming µCs until now and I thought about getting used to computers by making a virtual machine.
That way I have to learn every single aspect about the architecture, which is a necessity in my opinion.

I hope you can help me find the specification for the architecture (x86 probably).

Offline TightCoderEx

  • Full Member
  • **
  • Posts: 103
Re: Architecture? Instruction set?
« Reply #1 on: June 04, 2012, 10:21:41 PM »
http://download.intel.com/products/processor/manual/325462.pdf should give you everything you need, at least if your running a 64 bit processor

Offline Frank Kotler

  • NASM Developer
  • Hero Member
  • *****
  • Posts: 2373
  • Country: us
Re: Architecture? Instruction set?
« Reply #2 on: June 04, 2012, 10:28:27 PM »
Yeah, x86 or x86-64. "IA64" refers to the "Itanium", I think. There are other architectures available, but Nasm is for x86-64. I think you can probably find what you want here:

http://www.intel.com/content/www/us/en/processors/architectures-software-developer-manuals.html#

Best,
Frank

P.S. I see TightCoderEx has posted a slightly different link - probably a better one. I'll post anyway - won't hurt to have both...


Offline TightCoderEx

  • Full Member
  • **
  • Posts: 103
Re: Architecture? Instruction set?
« Reply #3 on: June 04, 2012, 10:35:47 PM »
Mine is just drilled a little deeper into the page your referring to Frank.  It's simply a combination of volumes 2A, 2B, 2C and 3A, 3B, 3C in pdf format.

Offline Xandaros

  • Jr. Member
  • *
  • Posts: 2
Re: Architecture? Instruction set?
« Reply #4 on: June 04, 2012, 10:58:00 PM »
Oh thanks.
I've got some questions, though:
The Intel 64 architecture sounds like it is specific for 64 bit processors. I'm fine with just 32 bit, as long as it runs my assembled and later compiled code.
Where is the difference between x86 and IA-32? (Here is what I think it is: x86 is an older architecture and IA-32 is compatible with x86 code)

My goal is to make a binary compiled by gcc run. Obviously, binaries assembled by NASM is a step, too. (Hence I am posting in this forum.)

Thanks for the help so far!