Subject: [LINUX:11784] Re: C'de Assembler (was Re: Re: turkce klavye)
From: Turan Yuksel (e109796@metu.edu.tr)
Date: Fri 31 Dec 1999 - 20:04:28 EET
Arkadaslar, iyi hos ama gas (GNU Assembler'in kabul ettigi kod cok farkli !!!
..daha dogrusu syntax. Bu konuda GNU Assembler'in info'sunda
"AT&T Syntax versus Intel Syntax" baslikli bir bolum olacak.
Bir de, int `ayricalikli' bir komut degil mi? Sizin bu numaralarin cogu cok
DOS dependent.
Bakin, basit bir program soyle yazilabilir:
[.......]
main:
pushl %ebp
movl %esp,%ebp
subl $8,%esp
movl $1,-4(%ebp)
addl $1235,-4(%ebp)
movl -8(%ebp),%edx
addl %edx,-4(%ebp)
pushl $.LC0
call puts
addl $4,%esp
movl $1,%eax
jmp .L1
.align 16
.L1:
movl %ebp,%esp
popl %ebp
ret
[...........]
On Thu, Dec 30, 1999 at 10:56:11AM +0200, kursat wrote:
> Bir de soyle dener misin ?
>
> #include<stdio.h>
> main(){
> getchar();
> __asm__ ( "mov Cx,0"
> "mov Dx,24779H"
> "mov BH,07"
> "mov Ax,0600H"
> "int 10H"
> );
> }
>
-- Turan Yuksel e1097963@ceng.metu.edu.tr Listeden cikmak icin: unsub linux mesajini listeci@bilkent.edu.tr'a gonderiniz. Lutfen Listeci icin MIME / HTML / Turkce Aksan kullanmayin. Liste arsivinin adresi: http://listweb.bilkent.edu.tr/