public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/40113]  New: C++, -fdata-sections not works with .progmem data
@ 2009-05-12 10:28 sb-sf at users dot sourceforge dot net
  2009-05-12 14:51 ` [Bug target/40113] [avr] " pinskia at gcc dot gnu dot org
  0 siblings, 1 reply; 2+ messages in thread
From: sb-sf at users dot sourceforge dot net @ 2009-05-12 10:28 UTC (permalink / raw)
  To: gcc-bugs

all data placed to single .progmem.data section.
test.cpp:
char __attribute__((__progmem__)) Test1[] = "test1";
char const __attribute__((__progmem__)) Test2[] = "test2";

void const * array[] = 
{
    Test1, Test2
};

cmd line:
avr-gcc  -mmcu=atmega8 -fdata-sections -Wall -Os -Wa,-ahlmsd=test.lst -c 
test.cpp -o test.o

listing:
   8                    .global Test1
   9                            .section        .progmem.data,"a",@progbits
  12                    Test1:
  13 0000 7465 7374             .string "test1"
  13      3100 
  14                    .global array
  15                            .section        .data.array,"aw",@progbits
  18                    array:
  19 0000 0000                  .word   Test1
  20 0002 0000                  .word   _ZL5Test2
  21                            .section        .progmem.data
  24                    _ZL5Test2:
  25 0006 7465 7374             .string "test2"
  25      3200 

here array placed into unique section .data.array, while Test1 and Test2 into
single section .progmem.data


-- 
           Summary: C++, -fdata-sections not works with .progmem data
           Product: gcc
           Version: 4.3.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: sb-sf at users dot sourceforge dot net
  GCC host triplet: x86
GCC target triplet: AVR


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40113


^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Bug target/40113] [avr] C++, -fdata-sections not works with .progmem data
  2009-05-12 10:28 [Bug c++/40113] New: C++, -fdata-sections not works with .progmem data sb-sf at users dot sourceforge dot net
@ 2009-05-12 14:51 ` pinskia at gcc dot gnu dot org
  0 siblings, 0 replies; 2+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2009-05-12 14:51 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from pinskia at gcc dot gnu dot org  2009-05-12 14:51 -------


*** This bug has been marked as a duplicate of 39456 ***


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|normal                      |enhancement
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |DUPLICATE


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40113


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-05-12 14:51 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-05-12 10:28 [Bug c++/40113] New: C++, -fdata-sections not works with .progmem data sb-sf at users dot sourceforge dot net
2009-05-12 14:51 ` [Bug target/40113] [avr] " pinskia at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).