[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[avr-libc-dev] [bug #50811] using -Wl, -u, vfprintf -lprintf_min causes
From: |
anonymous |
Subject: |
[avr-libc-dev] [bug #50811] using -Wl, -u, vfprintf -lprintf_min causes program to grow a lot |
Date: |
Sat, 15 Apr 2017 19:38:23 -0400 (EDT) |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Firefox/38.0 Iceweasel/38.8.0 |
URL:
<http://savannah.nongnu.org/bugs/?50811>
Summary: using -Wl,-u,vfprintf -lprintf_min causes program to
grow a lot
Project: AVR C Runtime Library
Submitted by: None
Submitted on: Sat 15 Apr 2017 11:38:22 PM UTC
Category: None
Severity: 3 - Normal
Priority: 5 - Normal
Item Group: None
Status: None
Percent Complete: 0%
Assigned to: None
Originator Email: address@hidden
Open/Closed: Open
Discussion Lock: Any
Release: 2.0.0
Fixed Release: None
_______________________________________________________
Details:
The documentation seems to be saying that using those flags is supposed to
save flash, but without them, a main() that does a single printf("foo\n");
gives me a 330 byte flash, while with them I get a 1330 byte flash.
If I remove the printf() call, I get flash sizes of 1228 or 228 with or
without the above mentioned printf-min flags, respectively.
It looks like somehow the printf-min flag ends up dragging in a bunch extra
code somehow?
The rest of my linker invocation looks like this:
avr-gcc -mmcu=atmega328p -lm -Wl,-gc-sections
-Wl,-Map=program_to_upload.out.map -o program_to_upload.out main.o
I think probably the documentation ought to mention this possibility, assuming
it isn't a bug.
_______________________________________________________
Reply to this item at:
<http://savannah.nongnu.org/bugs/?50811>
_______________________________________________
Message sent via/by Savannah
http://savannah.nongnu.org/
- [avr-libc-dev] [bug #50811] using -Wl, -u, vfprintf -lprintf_min causes program to grow a lot,
anonymous <=
- [avr-libc-dev] [bug #50811] using -Wl, -u, vfprintf -lprintf_min causes program to grow a lot, Dave Hylands, 2017/04/16
- [avr-libc-dev] [bug #50811] using -Wl, -u, vfprintf -lprintf_min causes program to grow a lot, anonymous, 2017/04/17
- [avr-libc-dev] [bug #50811] using -Wl, -u, vfprintf -lprintf_min causes program to grow a lot, Dave Hylands, 2017/04/17
- [avr-libc-dev] [bug #50811] using -Wl, -u, vfprintf -lprintf_min causes program to grow a lot, anonymous, 2017/04/17
- [avr-libc-dev] [bug #50811] using -Wl, -u, vfprintf -lprintf_min causes program to grow a lot, Dave Hylands, 2017/04/17
- [avr-libc-dev] [bug #50811] using -Wl, -u, vfprintf -lprintf_min causes program to grow a lot, Joerg Wunsch, 2017/04/17
- [avr-libc-dev] [bug #50811] using -Wl, -u, vfprintf -lprintf_min causes program to grow a lot, anonymous, 2017/04/17
- [avr-libc-dev] [bug #50811] using -Wl, -u, vfprintf -lprintf_min causes program to grow a lot, Joerg Wunsch, 2017/04/18