Linux -Blue forest free software | Return to home page | Site Map | Search WWW | Contact Us |
Your current position : Homepage > Free Software > Technological exchanges >Application Programming


    

Blue Forest http://www.lslnet.com at 10:18 on June 6, 2006


Rethat program compiled under Linux, on the instructions jmp

I wrote a short compilation redhat Linux code used to call it asm. Jmp which it says is "address>; order, I would like to address the use of the relative deviation, such as jmp 0x2a (jumping from 42 bytes jmp instructions, implementation of the next Directive), but the compiler to put 0x2a explained absolute address, the Executive reported Segmentation fault after fault.
How compiler (gcc) 0x2a interpreted as a relative address?

Code examples :
Void main () (
__asm__ ( "
Jmp 0x2a
Movl $ 0x1, %eax
        。
        。
        。      
Call 0x8048208
");
}


Will prawn exhibitions, thank you.

Rethat program compiled under Linux, on the instructions jmp

Linux compilation understand. But as we can to set up a branch, the branch address on behalf of the JMP, and then branch into BX family. BX:BP using GPS. This register is a few bars. Oh, had not met, forget all the.

Rethat program compiled under Linux, on the instructions jmp

[code]
Void main () (
__asm__ ( "
Jmp If were examined in the "------
Movl $ 0x1, %eax

1:                       <------
Xxxx

Call 0x8048208
");
}

[/code]

Jump indeed be translated into absolute, but they can use labeling.

Said one grade 1 :
If were examined in the first match forward one said

Rethat program compiled under Linux, on the instructions jmp

Mdkii &win_hate There are compiled on Linux
Find a place to
Thank the

Rethat program compiled under Linux, on the instructions jmp

Thank you, win_hate However, I do not set up some information on the label can be achieved relative jump. Is the compiler option.

This little information on the Internet, here is incomplete. If someone can provide a bit of information in this regard, I am also very grateful.

Rethat program compiled under Linux, on the instructions jmp

-->

Now things are everywhere online ah, is a grasp. I learned in the past when it was more miserable, little, but still the search.

Rethat program compiled under Linux, on the instructions jmp

-->

I can not remember the label of relative jump, but I do not. I think the label convenience.



 Privacy Policy  Copyright © 1999-2000 LSLNET.COM. All rights reserved. Blue Forest website owners. E-mail : Webmaster@lslnet.com