This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/52505] New: [avr]: __memx address space reading unintentionally from RAM
- From: "gjl at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 06 Mar 2012 11:25:53 +0000
- Subject: [Bug target/52505] New: [avr]: __memx address space reading unintentionally from RAM
- Auto-submitted: auto-generated
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52505
Bug #: 52505
Summary: [avr]: __memx address space reading unintentionally
from RAM
Classification: Unclassified
Product: gcc
Version: 4.7.0
Status: UNCONFIRMED
Keywords: wrong-code
Severity: normal
Priority: P3
Component: target
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: gjl@gcc.gnu.org
Target: avr
The __memx address space reader must determine at runtime from what memory area
to read and what instruction to use. To read one byte, ine sequence might look
like:
ld r24,Z
sbrs r25,7
lpm r24,Z
This is not correct because if the read is fram flash memory but the address
taken as RAM address points to the I/O area, the read might have an effect on
I/O register, for example clear a latch or buffer.