From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15485 invoked by alias); 5 Dec 2001 03:00:35 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 15464 invoked from network); 5 Dec 2001 03:00:32 -0000 Received: from unknown (HELO hall.mail.mindspring.net) (207.69.200.60) by sources.redhat.com with SMTP; 5 Dec 2001 03:00:32 -0000 Received: from sdn-ar-002watacop132.dialsprint.net ([206.133.235.196] helo=tcprincemobl) by hall.mail.mindspring.net with smtp (Exim 3.33 #1) id 16BSIO-0001iP-00; Tue, 04 Dec 2001 22:00:29 -0500 Message-ID: <000101c17d38$fe510e10$c4eb85ce@amr.corp.intel.com> From: "Tim Prince" To: "Graham Stott" , Cc: References: <20011204153416.A24659@disaster.jaj.com> <20011204155032.A24992@disaster.jaj.com> <00d001c17d05$4be398c0$160e10ac@hades> <3C0D3A05.6FE3602F@redhat.com> Subject: Re: Assembly in Gcc Date: Tue, 04 Dec 2001 19:00:00 -0000 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4522.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 X-SW-Source: 2001-12/txt/msg00199.txt.bz2 Much as I dislike the MSVC style, this would be a valuable contribution. ----- Original Message ----- From: "Graham Stott" To: Cc: Sent: Tuesday, December 04, 2001 1:03 PM Subject: Re: Assembly in Gcc > Mark, > > Mark Cuss wrote: > > > > Hello all, > > > > I am new to doing inline asembly in gcc and have a few questions - hopefully > > someone can help me out. > > > > I read the section of the manual on the doing inline assembly. It is quite > > different than the old Borland compiler I used to use on DOS - I could just > > put an "asm " and enclose all of my Intel syntax assmebly instructions > > inside there. Is there any way to do this in gcc? I found the intel_syntax > > directive and passed that in, but it seems that I still need to put %' s in > > front of register names, etc. > > > You might like to try ".intel_syntax noprefix" that avoids the needs to the % > on register names. > > > The project I am working on involves integrating a large chunk (~ 40 pages) > > of Intel assembly instructions into a program which I must compile with gcc. > > So, my goal is to be able to do something like this: > > > > asm { > > mov dx, 378 > > mov al, FF > > out dx, al > > } ; > > > > ... Without reformatting the code. Is this possible? > > > Not as things currently stand you have to convert the asm { ... } form into > GCC's own asm construct. > > Now it just so happens that I'm working on adding support of MS style inline > assembler in to GCC for the x86. It's in an advanced state and almost ready > to be submitted. > > > Thanks in advance > > > > > Mark > > Graham