[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[avr-gcc-list] address@hidden: Bug#160051: gcc-avr: Incorrect code with

From: Hakan Ardo
Subject: [avr-gcc-list] address@hidden: Bug#160051: gcc-avr: Incorrect code with register variable]
Date: Fri, 18 Oct 2002 09:19:51 +0200
User-agent: Mutt/1.3.24i

does anyone have a solution to this problem?

----- Forwarded message from Jerry Quinn <address@hidden> -----

Subject: Bug#160051: gcc-avr: Incorrect code with register variable
From: Jerry Quinn <address@hidden>
To: Debian Bug Tracking System <address@hidden>

Package: gcc-avr
Version: 1:3.2-1
Severity: normal

The following program is miscompiled.  Register r3 is pushed and 
popped by the prolog and epilog of the signal handler.  This
clobbers the value computed in the routine.

#include <io.h>
#include <sig-avr.h>
register uint8_t rpm_h asm("r3");


void main(void) { for (;;);}

Compile with: gcc-avr -O2 -ffreestanding -mmcu=atmega8 -S junk.c

Optimization level doesn't affect the appearance of the bug.

-- System Information
Debian Release: 3.0
Architecture: i386
Kernel: Linux wyvern 2.4.18-686 #1 Sun Apr 14 11:32:47 EST 2002 i686

Versions of packages gcc-avr depends on:
ii  binutils-avr                  2.13-1     Binary utilities that support Atme
ii  gcc-3.1                       1:3.1.1-2  The GNU C compiler.
ii  libc6                         2.2.5-14   GNU C Library: Shared libraries an

----- End forwarded message -----

Hakan Ardo <address@hidden>, http://master.debian.org/~hakan/
avr-gcc-list at http://avr1.org

reply via email to

[Prev in Thread] Current Thread [Next in Thread]