public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* c/7941: GCC-3.2 does not work well with c-code interrupt function
@ 2002-09-16 19:36 dong_geming
0 siblings, 0 replies; only message in thread
From: dong_geming @ 2002-09-16 19:36 UTC (permalink / raw)
To: gcc-gnats
>Number: 7941
>Category: c
>Synopsis: GCC-3.2 does not work well with c-code interrupt function
>Confidential: no
>Severity: critical
>Priority: medium
>Responsible: unassigned
>State: open
>Class: mistaken
>Submitter-Id: net
>Arrival-Date: Mon Sep 16 19:36:00 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator: Adam Tong
>Release: GCC-3.2
>Organization:
>Environment:
cygwin
>Description:
I use the gcc-3.2 for arm to compile a C-Code interrupt function, the results is very diffrent when the option
'-mthumb-interwork' is used or not.
1: If the '-mthumb-interwork' is not used, code "ldmdb fp, {r3, fp, ip, lr}^" will be generated, is this wrong?
2: If the '-mthumb-interwork' is not used, code "ldmdb fp, {r3, fp, ip, pc}^" will be generated, is this right?
Compile by command: arm-elf-gcc -mthumb-interwork -gdwarf -c .\irq.c -o.\irq.o
Please reply me as soon as possible. thanks
(86)755-25620636-810
Adam Tong
>How-To-Repeat:
/************** Source file Start************************/
void ext_IRQ0_handler(void) __attribute__ ((interrupt ("IRQ")));
/*-----------------------------------------------------*/
/* Function Name : ext_IRQ0_handler */
/*-----------------------------------------------------*/
void ext_IRQ0_handler(void)
{
int i = 1;
return;
}
/************** Source file End***********************/
/***Compile Command without "-mthumb-interwork" *******/
arm-elf-gcc -gdwarf -c irq.c -o irq.o
/***Compile Command with "-mthumb-interwork" *******/
arm-elf-gcc -mthumb-interwork -gdwarf -c irq.c -o irq.o
Disassemble : arm-elf-objdump -d irq.o
you will discover their different.
>Fix:
Maybe the cpp.exe is wrong.
Please reply me as soon as possible. thanks
(86)755-25620636-810
Adam Tong
>Release-Note:
>Audit-Trail:
>Unformatted:
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2002-09-17 2:36 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-09-16 19:36 c/7941: GCC-3.2 does not work well with c-code interrupt function dong_geming
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).