![]() |
Show 150 posts per page |
.dsy:it. (http://www.dsy.it/forum/)
- Sicurezza (http://www.dsy.it/forum/forumdisplay.php?forumid=264)
-- stack pointer (http://www.dsy.it/forum/showthread.php?threadid=43482)
stack pointer
ragazzi non capisco una cosa:
in x86 assembler le istruzioni sono del tipo: destinazione, sorgente.
quindi se faccio: mov eax,10 metto il valore 10 in eax.
il problema è:
code:
unsigned long sp(void) { __asm__("movl %esp, %eax"); } void main(void) { printf("0x%x\n", sp()); }
__________________
Live Fast, Die Fun
ok ho trovato la risposta: il compilatore gcc usa la sintassi AT&T, quindi sorgente, destinazione... risolto
__________________
Live Fast, Die Fun
appena vedi dei % è at&t
| All times are GMT. The time now is 18:18. | Show all 3 posts from this thread on one page |
Powered by: vBulletin Version 2.3.1
Copyright © Jelsoft Enterprises Limited 2000 - 2002.