public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/28755]  New: duplicate members of arrays
@ 2006-08-16 17:28 dwmw2 at infradead dot org
  2006-08-16 17:29 ` [Bug c/28755] " dwmw2 at infradead dot org
                   ` (14 more replies)
  0 siblings, 15 replies; 16+ messages in thread
From: dwmw2 at infradead dot org @ 2006-08-16 17:28 UTC (permalink / raw)
  To: gcc-bugs

See attached test case. Observe the number of times certain lines of the
'vesa_modes' array are emitted. This isn't particularly optimal, especially as
it happens even with -Os.

 $ make
cc -Os -c -o fbmon.o fbmon.i -save-temps
grep 39682 fbmon.s
        .long   39682
        .long   39682


-- 
           Summary: duplicate members of arrays
           Product: gcc
           Version: 4.1.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: dwmw2 at infradead dot org


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


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

* [Bug c/28755] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
@ 2006-08-16 17:29 ` dwmw2 at infradead dot org
  2006-08-16 17:36 ` [Bug middle-end/28755] " pinskia at gcc dot gnu dot org
                   ` (13 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: dwmw2 at infradead dot org @ 2006-08-16 17:29 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from dwmw2 at infradead dot org  2006-08-16 17:29 -------
Created an attachment (id=12084)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=12084&action=view)
test case


-- 


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


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

* [Bug middle-end/28755] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
  2006-08-16 17:29 ` [Bug c/28755] " dwmw2 at infradead dot org
@ 2006-08-16 17:36 ` pinskia at gcc dot gnu dot org
  2006-08-16 17:37 ` pinskia at gcc dot gnu dot org
                   ` (12 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-08-16 17:36 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from pinskia at gcc dot gnu dot org  2006-08-16 17:36 -------
This is an expand/middle-end issue as get:
  *mode = vesa_modes[0];
in the final_cleanup.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|c                           |middle-end
           Keywords|                            |missed-optimization


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


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

* [Bug middle-end/28755] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
  2006-08-16 17:29 ` [Bug c/28755] " dwmw2 at infradead dot org
  2006-08-16 17:36 ` [Bug middle-end/28755] " pinskia at gcc dot gnu dot org
@ 2006-08-16 17:37 ` pinskia at gcc dot gnu dot org
  2006-08-16 17:40 ` [Bug middle-end/28755] [4.0/4.1/4.2 Regression] " pinskia at gcc dot gnu dot org
                   ` (11 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-08-16 17:37 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from pinskia at gcc dot gnu dot org  2006-08-16 17:37 -------
Confirmed, here is the testcase for lazy people (like me) who really don't want
to download the tar file:
struct fb_videomode {
 const char *name;
 unsigned refresh;
 unsigned xres;
 unsigned yres;
 unsigned pixclock;
 unsigned left_margin;
 unsigned right_margin;
 unsigned upper_margin;
 unsigned lower_margin;
 unsigned hsync_len;
 unsigned vsync_len;
 unsigned sync;
 unsigned vmode;
 unsigned flag;
};

const struct fb_videomode vesa_modes[] = {

 { ((void *)0), 60, 640, 480, 39682, 48, 16, 33, 10, 96, 2,
   0, 0, 4 },
};

void get_est_timing(unsigned char *block, struct fb_videomode *mode)
{
        mode[0] = vesa_modes[0];
}
-------
Oh this is not a regression as far as I can tell.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
      Known to fail|                            |3.3.5 4.2.0
   Last reconfirmed|0000-00-00 00:00:00         |2006-08-16 17:37:29
               date|                            |


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


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

* [Bug middle-end/28755] [4.0/4.1/4.2 Regression] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
                   ` (2 preceding siblings ...)
  2006-08-16 17:37 ` pinskia at gcc dot gnu dot org
@ 2006-08-16 17:40 ` pinskia at gcc dot gnu dot org
  2006-08-17 11:18 ` jakub at gcc dot gnu dot org
                   ` (10 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-08-16 17:40 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from pinskia at gcc dot gnu dot org  2006-08-16 17:39 -------
Actually it is a regression from 2.95.3, I just had to go back in time enough
to get find that.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to fail|3.3.5 4.2.0                 |3.3.5 4.2.0 3.2.3 3.3.3
                   |                            |3.0.4
      Known to work|                            |2.95.3
            Summary|duplicate members of arrays |[4.0/4.1/4.2 Regression]
                   |                            |duplicate members of arrays
   Target Milestone|---                         |4.0.4


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


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

* [Bug middle-end/28755] [4.0/4.1/4.2 Regression] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
                   ` (3 preceding siblings ...)
  2006-08-16 17:40 ` [Bug middle-end/28755] [4.0/4.1/4.2 Regression] " pinskia at gcc dot gnu dot org
@ 2006-08-17 11:18 ` jakub at gcc dot gnu dot org
  2006-08-20 22:49 ` mmitchel at gcc dot gnu dot org
                   ` (9 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: jakub at gcc dot gnu dot org @ 2006-08-17 11:18 UTC (permalink / raw)
  To: gcc-bugs



-- 

jakub at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |jakub at gcc dot gnu dot org
                   |dot org                     |
                URL|                            |http://gcc.gnu.org/ml/gcc-
                   |                            |patches/2006-
                   |                            |08/msg00601.html
             Status|NEW                         |ASSIGNED
   Last reconfirmed|2006-08-16 17:37:29         |2006-08-17 11:17:59
               date|                            |


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


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

* [Bug middle-end/28755] [4.0/4.1/4.2 Regression] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
                   ` (4 preceding siblings ...)
  2006-08-17 11:18 ` jakub at gcc dot gnu dot org
@ 2006-08-20 22:49 ` mmitchel at gcc dot gnu dot org
  2006-08-21  4:29 ` patchapp at dberlin dot org
                   ` (8 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2006-08-20 22:49 UTC (permalink / raw)
  To: gcc-bugs



-- 

mmitchel at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P3                          |P2


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


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

* [Bug middle-end/28755] [4.0/4.1/4.2 Regression] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
                   ` (5 preceding siblings ...)
  2006-08-20 22:49 ` mmitchel at gcc dot gnu dot org
@ 2006-08-21  4:29 ` patchapp at dberlin dot org
  2007-02-03 18:56 ` [Bug middle-end/28755] [4.0/4.1/4.2/4.3 " gdr at gcc dot gnu dot org
                   ` (7 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: patchapp at dberlin dot org @ 2006-08-21  4:29 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from patchapp at dberlin dot org  2006-08-21 04:29 -------
Subject: Bug number PR middle-end/28755

A patch for this bug has been added to the patch tracker.
The mailing list url for the patch is
http://gcc.gnu.org/ml/gcc-patches/2006-08/msg00601.html


-- 


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


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

* [Bug middle-end/28755] [4.0/4.1/4.2/4.3 Regression] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
                   ` (6 preceding siblings ...)
  2006-08-21  4:29 ` patchapp at dberlin dot org
@ 2007-02-03 18:56 ` gdr at gcc dot gnu dot org
  2007-02-03 20:55 ` pinskia at gcc dot gnu dot org
                   ` (6 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: gdr at gcc dot gnu dot org @ 2007-02-03 18:56 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from gdr at gcc dot gnu dot org  2007-02-03 18:56 -------
Won't fix in GCC-4.0.x.  Adjusting milestone.


-- 

gdr at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.0.4                       |4.1.3


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


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

* [Bug middle-end/28755] [4.0/4.1/4.2/4.3 Regression] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
                   ` (7 preceding siblings ...)
  2007-02-03 18:56 ` [Bug middle-end/28755] [4.0/4.1/4.2/4.3 " gdr at gcc dot gnu dot org
@ 2007-02-03 20:55 ` pinskia at gcc dot gnu dot org
  2007-02-14  9:21 ` mmitchel at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-02-03 20:55 UTC (permalink / raw)
  To: gcc-bugs



-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.1.3                       |4.1.2


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


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

* [Bug middle-end/28755] [4.0/4.1/4.2/4.3 Regression] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
                   ` (8 preceding siblings ...)
  2007-02-03 20:55 ` pinskia at gcc dot gnu dot org
@ 2007-02-14  9:21 ` mmitchel at gcc dot gnu dot org
  2007-09-23  9:35 ` jakub at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2007-02-14  9:21 UTC (permalink / raw)
  To: gcc-bugs



-- 

mmitchel at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.1.2                       |4.1.3


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


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

* [Bug middle-end/28755] [4.0/4.1/4.2/4.3 Regression] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
                   ` (9 preceding siblings ...)
  2007-02-14  9:21 ` mmitchel at gcc dot gnu dot org
@ 2007-09-23  9:35 ` jakub at gcc dot gnu dot org
  2007-09-24  6:36 ` [Bug middle-end/28755] [4.0/4.1/4.2 " jakub at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: jakub at gcc dot gnu dot org @ 2007-09-23  9:35 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #7 from jakub at gcc dot gnu dot org  2007-09-23 09:34 -------
Subject: Bug 28755

Author: jakub
Date: Sun Sep 23 09:34:28 2007
New Revision: 128685

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=128685
Log:
        PR middle-end/28755
        * expr.c (expand_constructor): New function.
        (expand_expr_real_1) <case CONSTRUCTOR>: Call it.
        (expand_expr_real_1) <case ARRAY_REF>: Call it if VALUE is
        CONSTRUCTOR.

        * gcc.dg/pr28755.c: New test.

Added:
    trunk/gcc/testsuite/gcc.dg/pr28755.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/expr.c
    trunk/gcc/testsuite/ChangeLog


-- 


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


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

* [Bug middle-end/28755] [4.0/4.1/4.2 Regression] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
                   ` (10 preceding siblings ...)
  2007-09-23  9:35 ` jakub at gcc dot gnu dot org
@ 2007-09-24  6:36 ` jakub at gcc dot gnu dot org
  2008-01-15 19:13 ` alexandre dot nunes at gmail dot com
                   ` (2 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: jakub at gcc dot gnu dot org @ 2007-09-24  6:36 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #8 from jakub at gcc dot gnu dot org  2007-09-24 06:36 -------
Fixed on the trunk.


-- 

jakub at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to work|2.95.3                      |2.95.3 4.3.0
            Summary|[4.0/4.1/4.2/4.3 Regression]|[4.0/4.1/4.2 Regression]
                   |duplicate members of arrays |duplicate members of arrays


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


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

* [Bug middle-end/28755] [4.0/4.1/4.2 Regression] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
                   ` (11 preceding siblings ...)
  2007-09-24  6:36 ` [Bug middle-end/28755] [4.0/4.1/4.2 " jakub at gcc dot gnu dot org
@ 2008-01-15 19:13 ` alexandre dot nunes at gmail dot com
  2008-07-04 21:28 ` [Bug middle-end/28755] [4.2 " jsm28 at gcc dot gnu dot org
  2009-03-30 17:04 ` jsm28 at gcc dot gnu dot org
  14 siblings, 0 replies; 16+ messages in thread
From: alexandre dot nunes at gmail dot com @ 2008-01-15 19:13 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #9 from alexandre dot nunes at gmail dot com  2008-01-15 18:12 -------
(In reply to comment #8)
> Fixed on the trunk.
> 

For anyone else wondering, this is still reproductible on vanilla gcc 4.2.2.


-- 


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


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

* [Bug middle-end/28755] [4.2 Regression] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
                   ` (12 preceding siblings ...)
  2008-01-15 19:13 ` alexandre dot nunes at gmail dot com
@ 2008-07-04 21:28 ` jsm28 at gcc dot gnu dot org
  2009-03-30 17:04 ` jsm28 at gcc dot gnu dot org
  14 siblings, 0 replies; 16+ messages in thread
From: jsm28 at gcc dot gnu dot org @ 2008-07-04 21:28 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #10 from jsm28 at gcc dot gnu dot org  2008-07-04 21:27 -------
Closing 4.1 branch.


-- 

jsm28 at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|[4.1/4.2 Regression]        |[4.2 Regression] duplicate
                   |duplicate members of arrays |members of arrays
   Target Milestone|4.1.3                       |4.2.5


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


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

* [Bug middle-end/28755] [4.2 Regression] duplicate members of arrays
  2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
                   ` (13 preceding siblings ...)
  2008-07-04 21:28 ` [Bug middle-end/28755] [4.2 " jsm28 at gcc dot gnu dot org
@ 2009-03-30 17:04 ` jsm28 at gcc dot gnu dot org
  14 siblings, 0 replies; 16+ messages in thread
From: jsm28 at gcc dot gnu dot org @ 2009-03-30 17:04 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #11 from jsm28 at gcc dot gnu dot org  2009-03-30 17:03 -------
Closing 4.2 branch, fixed in 4.3.


-- 

jsm28 at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
      Known to fail|3.3.5 4.2.0 3.2.3 3.3.3     |3.3.5 4.2.0 3.2.3 3.3.3
                   |3.0.4 4.0.4                 |3.0.4 4.0.4 4.2.5
         Resolution|                            |FIXED
   Target Milestone|4.2.5                       |4.3.0


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


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

end of thread, other threads:[~2009-03-30 17:04 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-08-16 17:28 [Bug c/28755] New: duplicate members of arrays dwmw2 at infradead dot org
2006-08-16 17:29 ` [Bug c/28755] " dwmw2 at infradead dot org
2006-08-16 17:36 ` [Bug middle-end/28755] " pinskia at gcc dot gnu dot org
2006-08-16 17:37 ` pinskia at gcc dot gnu dot org
2006-08-16 17:40 ` [Bug middle-end/28755] [4.0/4.1/4.2 Regression] " pinskia at gcc dot gnu dot org
2006-08-17 11:18 ` jakub at gcc dot gnu dot org
2006-08-20 22:49 ` mmitchel at gcc dot gnu dot org
2006-08-21  4:29 ` patchapp at dberlin dot org
2007-02-03 18:56 ` [Bug middle-end/28755] [4.0/4.1/4.2/4.3 " gdr at gcc dot gnu dot org
2007-02-03 20:55 ` pinskia at gcc dot gnu dot org
2007-02-14  9:21 ` mmitchel at gcc dot gnu dot org
2007-09-23  9:35 ` jakub at gcc dot gnu dot org
2007-09-24  6:36 ` [Bug middle-end/28755] [4.0/4.1/4.2 " jakub at gcc dot gnu dot org
2008-01-15 19:13 ` alexandre dot nunes at gmail dot com
2008-07-04 21:28 ` [Bug middle-end/28755] [4.2 " jsm28 at gcc dot gnu dot org
2009-03-30 17:04 ` jsm28 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).