Jump to content

Assembly language, Where to start?


OtterFox

Recommended Posts

Looking to start assembly language. I have some experience with C and am interested in getting lower.

I know nothing about it so what sort of things would I need to know first and wheres a good starting point?(web site maybe?)

Link to comment
Share on other sites

When I was first taught ASM (so long ago I can't remember the language anymore) my teacher started with explaining the Motorola 68000 processor. Apparently its instruction set is particularly clean and consistent or something. What it boils down to is that you should start ASM on a platform that is available to you. The 68K meant the old(-ish) Macs. Find a book that explains ASM to you. You're probably better off that way.

Link to comment
Share on other sites

@dualism: Thanks looks nice.

@Cooper: Whats do you know anything about the different types of assembly, I was looking at some books and they were all for different types of x86(which is fine because I will use a duron CPU) but for intel assembly compilers or AT&T compilers and most cater for either Linux or Windows/DOS. Which is the best compiler to learn with and is there a OS independent type of assembly?

Link to comment
Share on other sites

I started with Paul Carter's excellent PC Assembly Language.

http://www.drpaulcarter.com/pcasm/

I never really bought into HLA (High level assembly from Art of Assembly), so it was really nice to find "pcasm". It starts you off with x86 asm using intel syntax, which is good and bad (imho it's easier to learn than AT&T syntax, but you need to get used to AT&T if you're going to disassemble in gdb). You start off learning how to write useful(?) programs, using a C wrapper, so you don't get overwhelmed from the start having to memorize syscalls.

good luck!

Link to comment
Share on other sites

Most people will tell you that the Art of Assembly is the best place to go, I have some philisophical issues with High-level assembly, so I stand by my above recommendation.

Yea I read the read the thread about books to read, and checked out the book that metatron recommended(the art of assembly) and then I looked at it on amazon and found comments about it being about High-Level assembly and sort of decided that I might as well learn proper assembly.

In regards to the books Cooper mentioned, they preovide AMAZING reference, but you really don't need/want them until you understand how assembly works. That is, you don't need to read about PSRLW until you can explain

I was thinking that too. But Ive bookmarked them for later.

I also read the Intel syntax was easier too.

Is it very hard to change form Intel to AT&T syntax later? Because I wouldn't mind doing that because I also want get into disassembling things.

Link to comment
Share on other sites

It's not *taht* bad going from intel to AT&T. its all the same concepts, and mostly the same syntax, there are just some differences that you need to be aware of. for example, in intel syntax, you do

[instruction]  [destination],[source]

int AT&T, you do

[instruction]  [source], [destination],

for example, to load the value stored in ebx into eax, it would look like:

intel:

mov  eax,ebx

AT&T:

mov %ebx,%eax

as you can see, another difference is that in at&t, registers are prefixed with a %.

so theres a lot of little things like that. if you google for it, you can find concise 2 page-ish summaries of the differences.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...