New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

avr-gcc, avr-libc compiler and toolchain known bugs #1208

WestfW opened this Issue Jan 10, 2013 · 2 comments


4 participants

WestfW commented Jan 10, 2013

This "issues" is supposed to collect "known" problems with tool versions that are not actually in use. So it's not so much a bug to be fixed as a warning sign for experimenters.

The Arduino environment, as of version 1.0.2, uses avr-gcc version 4.3.2, binutils 2.19, and avr-libc 1.6.4 These are pretty old. But several more recent versions have serious bugs when one attempts to use them with Arduino.

  1. Global Constructor bug.
    This is the bug that infamously caused any Arduino MEGA sketches to fail at runtime in large sketches when compiled under linux with the 4.5.3 release.
    Arduino issue
    This is avr-gcc bug:
    It broke in 4.4.something, is known broken in 4.5.3 and 4.6.0, and known fixed in 4.5.4, 4.6.1, and 4.7.0

  2. "round()" incompatibility

  3. byte assembly (shift) bug
    (broken in 4.4.0, 4.5.3, 4.6.1. Fixed in 4.5.4, 4.6.2, 4.7.0)

  4. delay() bug introduced with binutils 2.21.1

  5. util/delay.h bug wrt math.h

  6. progmem is used wrong, nearly everywhere. Mostly this breaks g++
    (avr-gcc 4.7.2 apparently significantly changes the way progmem is handled?)

I'll add more when and if I find or remember them...


This comment has been minimized.

amcjen commented Jan 11, 2013

Thanks Bill for posting these. This really helps to understand what is actually broken where. Appreciate you putting these up.


This comment has been minimized.


ffissore commented May 27, 2015

Fixed. See #611

@ffissore ffissore closed this May 27, 2015

@ffissore ffissore added this to the Release 1.6.5 milestone May 27, 2015

@ffissore ffissore self-assigned this May 27, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment