avr-libc-dev
[Top][All Lists]
Advanced

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

[avr-libc-dev] [patch #6352] Far pointer library


From: Jan Waclawek
Subject: [avr-libc-dev] [patch #6352] Far pointer library
Date: Wed, 03 Aug 2011 21:06:03 +0000
User-agent: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.2.18) Gecko/20110614 Firefox/3.6.18

Follow-up Comment #7, patch #6352 (project avr-libc):

The _PF functions in the respective binary libraries are broken, and they ever
were, since the've been added to avr-libc in 1.7.0.

They don't use the ELPM instruction rather, incorrectly, the LPM instruction.

The reason is, that these functions rely on LPM_R0_ZPLUS_NEXT macro in
common/macros.inc, which uses the BIG_CODE macro defined in the same file to
determine whether LPM or ELPM is appropriate.

BIG_CODE is defined according to FLASHEND macro which comes from the
individual files' headers (additionally, the RAMPZ register's address might be
needed for some of the files). However, these files are compiled with the
"generic" -mavrN switch, so the FLASHEND macro is unavailable thus considered
zero by preprocessor.

This bug was originally reported here
http://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&t=110170



    _______________________________________________________

Reply to this item at:

  <http://savannah.nongnu.org/patch/?6352>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.nongnu.org/




reply via email to

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