From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26291 invoked by alias); 19 Feb 2002 15:40:34 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 26133 invoked from network); 19 Feb 2002 15:40:15 -0000 Received: from unknown (HELO fencepost.gnu.org) (199.232.76.164) by sources.redhat.com with SMTP; 19 Feb 2002 15:40:15 -0000 Received: from ihemail1.lucent.com ([192.11.222.161] helo=ihemail1.firewall.lucent.com) by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian)) id 16dCND-0006RJ-00 for ; Tue, 19 Feb 2002 10:40:07 -0500 Received: from nj7460exch002h.wins.lucent.com (h135-17-42-35.lucent.com [135.17.42.35]) by ihemail1.firewall.lucent.com (Switch-2.1.3/Switch-2.1.0) with ESMTP id g1JFe4g13636 for ; Tue, 19 Feb 2002 10:40:04 -0500 (EST) Received: by nj7460exch002h.ho.lucent.com with Internet Mail Service (5.5.2650.21) id ; Tue, 19 Feb 2002 10:40:03 -0500 Message-ID: From: "Noonan, Michael E (Michael)" To: "'Dylan Cuthbert'" , "Noonan, Michael E (Michael)" , help-gcc@gnu.org Subject: RE: assembly macro syntax... Date: Tue, 19 Feb 2002 15:26:00 -0000 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2650.21) Content-Type: text/plain; charset="iso-8859-1" X-SW-Source: 2002-02/txt/msg00184.txt.bz2 ok... i have gotten a little further and have a new issue... basically all the macros that i converted are compiling without error, but there when i try and use the output of any of them, the compiler chokes on it with the error message shown below. The actual code is also shown.... and all it does is read from a gpr and then prints the result (output). If i co the printf statement, it compiles without error. Any help is appreciated. Thanks, Mike __asm__ ( "mr %0 %1" : "=&r" (output) : "r" (1) ); // __asm__ ( "or %0 %1 %2" : "=g" (output) : "g" (1), "g" (1) ); dprintf (DPRINT_LF, "Current r1 Stack: 0x%x.", output ); [d:\exs2_rom\hdl\smc]make vxWorks mkvers2 build.c build.sav -b Mkvers2, ver. 4.1, Jun 28 2001 Mnoo Output File : build.c Source File : build.sav Build Info : 0.0.0:289- Builder Name: ccppc -BC:\Tornado/host/x86-win32/lib/gcc-lib/ -c build.c -o build.o ccppc -BC:\Tornado/host/x86-win32/lib/gcc-lib/ -mstrict-align -DVXWORKS_HDL_BUILD -nostdinc -g -O2 -fvolatil e -fno-builtin -fno-for-scope -Wall -I./h -IC:\Tornado\target\config\smc8260 -I..\h -I..\h\diag -I..\h\drv -I . -IC:\Tornado\target\config\all -IC:\Tornado\target/h -IC:\Tornado\target/src/config -IC:\Tornado\target/src /drv -DCPU=PPCEC603 -msoft-float -c ..\src\diag/excpTest.c d:\TEMP\cca00272.s: Assembler messages: d:\TEMP\cca00272.s:935: Error: syntax error; found `1' but expected `,' d:\TEMP\cca00272.s:935: Error: junk at end of line: `11' ccppc: Internal compiler error: program as got fatal signal 1 make: *** [excpTest.o] Error 0x1 [d:\exs2_rom\hdl\smc] -----Original Message----- From: Dylan Cuthbert [mailto:dylan@q-games.com] Sent: Monday, February 18, 2002 10:31 PM To: Dylan Cuthbert; Noonan, Michael E (Michael); help-gcc@gnu.org Subject: Re: assembly macro syntax... sorry about that... remove the .html from the URL: http://www.geocities.com/dylan_cuthbert --------------------------------- Q-Games, Dylan Cuthbert. http://www.q-games.com ----- Original Message ----- From: "Dylan Cuthbert" To: "Noonan, Michael E (Michael)" ; Sent: Tuesday, February 19, 2002 10:58 AM Subject: Re: assembly macro syntax... > check out my page which some info and links on it regarding gcc's asm > statement- http://www.geocities.com/dylan_cuthbert.html > > Regards > --------------------------------- > Q-Games, Dylan Cuthbert. > http://www.q-games.com > ----- Original Message ----- > From: "Noonan, Michael E (Michael)" > To: "Noonan, Michael E (Michael)" ; > Sent: Tuesday, February 19, 2002 1:51 AM > Subject: RE: assembly macro syntax... > > > > > > > I have a simple question for anyone who knows how to write assembly > macros > > > for the GNU compiler. I am trying to port macros that target the Diab > > > compiler for PPC and am having a hell of a time figuring out the correct > > > syntax. The macros are used to test the PPC exception handler by > forcing > > > the respective exceptions. Here are a couple of the Diab format > assembly > > > macros for reference... > > > > > > VOID excpTestPage (ULONG input) > > > { > > > asm (" lwz r4,0(r3)"); > > > } > > > > > > VOID excpTestIsi (VOID) > > > { > > > asm (" .long 0x4BC00001"); // branch to 0x0F00_0000 + ip > > > } > > > > > > VOID excpTestTrap (ULONG input) > > > { > > > asm (" twgti r3,5"); // trap if input is greater than 5 > > > } > > > > > > I have scoured the GCC manual and cannot figure it out from the given > > > info. > > > > > > Any help is greatly appreciated. Thanks, Mike >