FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Debian > Debian User

 
 
LinkBack Thread Tools
 
Old 09-22-2008, 06:42 PM
I Rattan
 
Default GAS and int $0x80

The following code works on plain P4 Linux but fails
on AMD Linux with 'Segmentation fault' at the instruction:

int $0x80

Any ideas?
-ishwar
---
/* Hello, world in assembly.. */

.data
hello: .string "Hello, world!
"
.text
.global main
main: movl $4,%eax
movl $1, %ebx
movl $hello,%ecx
movl $14,%edx
int $0x80

movl $1, %eax
xorl %ebx,%ebx
int $0x80
ret
---------


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
 

Thread Tools




All times are GMT. The time now is 07:39 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org