Quantcast
Channel: Confused about assembly instructions - Stack Overflow
Browsing all 4 articles
Browse latest View live

Answer by Martin Rosenau for Confused about assembly instructions

If you want to ask "why does the program not look like this?":_main: mov $0, %eax ; sub %eax, %eax would be more efficient retYou are absolutely right. The following four instructions:pushl %ebpmovl...

View Article



Answer by EOF for Confused about assembly instructions

Let's look at a sequence of instructions:1. nop #call-stack is aligned to 16 bytes (sp is multiple of 16) to start.2. call function #pushes return address (4 bytes) onto stack.---(called function)3....

View Article

Answer by user267885 for Confused about assembly instructions

How functions are called on the machine language level is mandated by something called a calling convention that is usually architecture and OS-specific. It is designed so that you can call other...

View Article

Confused about assembly instructions

I was reading this tutorial on assembly: http://orangejuiceliberationfront.com/intel-assembler-on-mac-os-x/ and I came across this basic assembly code: .text.globl _main_main: pushl %ebp movl %esp,...

View Article
Browsing all 4 articles
Browse latest View live




Latest Images