🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.gcc.help
Article #50726

Re: GCC asm in-line on 386 code?

#50726
From: Michael Strauch
Date: Mon, 16 Aug 1993 10:24
18 lines
1330 bytes
jzh@abb-sc.abb-sc.com (Jason Huang) writes:


>Anybody like to point me out on assembler instruction
>using 'asm' please? For I/O instructions, IN AL,DX; OUT DX,AL.

Try this one: asm("inb %dx,%al");
              asm("outb %al,%dx");

This is not INTEL syntax, but AT&T syntax. The main difference is the
sequence of the operands - in AT&T syntax the first one is the source
operand and the second one is the destination operand. For a
full description get a complete GAS manual (written in TeX) from
one of the various ftp-servers. It contains a lot of machine dependent
stuff especially for the '386.

- Michael Strauch -
strauch@emmy.mathematik.uni-dortmund.de
Technical Details
Message-ID: <24nn9pINNh0l@unidoct.Chemietechnik.Uni-Dortmund.DE>
Path: arc1-ca.pugleaf.net!gmd.de!Germany.EU.net!Informatik.Uni-Dortmund.DE!Chemietechnik.Uni-Dortmund.DE!strauch
References: <1760@abb-sc.abb-sc.COM>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 11318c,636eb8e2b1c1a855
X-Google-Attributes: gid11318c,public
X-Google-ArrivalTime: 1993-08-16 04:05:21 PST
Path: arc1-ca.pugleaf.net!gmd.de!Germany.EU.net!Informatik.Uni-Dortmund.DE!Chemietechnik.Uni-Dortmund.DE!strauch
From: strauch@emmy.mathematik.uni-dortmund.de (Michael Strauch)
Newsgroups: gnu.gcc.help
Subject: Re: GCC asm in-line on 386 code?
Date: 16 Aug 1993 10:24:57 GMT
Organization: Universitaet Dortmund, CT, Germany
Lines: 19
Message-ID: <24nn9pINNh0l@unidoct.Chemietechnik.Uni-Dortmund.DE>
References: <1760@abb-sc.abb-sc.COM>
NNTP-Posting-Host: emmy.mathematik.uni-dortmund.de