public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/42555]  New: 4.5 regression: 16-byte aligned double is disallowed only in templates
@ 2009-12-30 18:57 bredelin at ucla dot edu
  2009-12-30 19:00 ` [Bug c++/42555] " bredelin at ucla dot edu
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: bredelin at ucla dot edu @ 2009-12-30 18:57 UTC (permalink / raw)
  To: gcc-bugs

The following line of code is accepted:

typedef double AlignedDoubleType __attribute__((aligned(16)));

However, if I replace 'double' with a template parameter inside a template
function, then I get the following error message:

error: alignment of array elements is greater than element size

I think that the template version of the typedef should be allowed also, as it
is in 4.4.


-- 
           Summary: 4.5 regression: 16-byte aligned double is disallowed
                    only in templates
           Product: gcc
           Version: 4.5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: bredelin at ucla dot edu
 GCC build triplet: x86_64-linux-gnu
  GCC host triplet: x86_64-linux-gnu
GCC target triplet: x86_64-linux-gnu


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


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

* [Bug c++/42555] 4.5 regression: 16-byte aligned double is disallowed only in templates
  2009-12-30 18:57 [Bug c++/42555] New: 4.5 regression: 16-byte aligned double is disallowed only in templates bredelin at ucla dot edu
@ 2009-12-30 19:00 ` bredelin at ucla dot edu
  2009-12-30 19:04 ` bredelin at ucla dot edu
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: bredelin at ucla dot edu @ 2009-12-30 19:00 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from bredelin at ucla dot edu  2009-12-30 19:00 -------
Created an attachment (id=19425)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=19425&action=view)
A testcase.

To reproduce the error, compile the file (test5.C) with this command line:
% g++-4.5 -c test5.C -O3


-- 


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


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

* [Bug c++/42555] 4.5 regression: 16-byte aligned double is disallowed only in templates
  2009-12-30 18:57 [Bug c++/42555] New: 4.5 regression: 16-byte aligned double is disallowed only in templates bredelin at ucla dot edu
  2009-12-30 19:00 ` [Bug c++/42555] " bredelin at ucla dot edu
@ 2009-12-30 19:04 ` bredelin at ucla dot edu
  2010-01-01 20:35 ` [Bug c++/42555] [4.5 Regression] " rguenth at gcc dot gnu dot org
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: bredelin at ucla dot edu @ 2009-12-30 19:04 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from bredelin at ucla dot edu  2009-12-30 19:03 -------
Also, I just noticed that the error occurs only if -ftree-vectorize is turned
on.


-- 


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


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

* [Bug c++/42555] [4.5 Regression] 16-byte aligned double is disallowed only in templates
  2009-12-30 18:57 [Bug c++/42555] New: 4.5 regression: 16-byte aligned double is disallowed only in templates bredelin at ucla dot edu
  2009-12-30 19:00 ` [Bug c++/42555] " bredelin at ucla dot edu
  2009-12-30 19:04 ` bredelin at ucla dot edu
@ 2010-01-01 20:35 ` rguenth at gcc dot gnu dot org
  2010-01-01 23:48 ` hjl dot tools at gmail dot com
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-01-01 20:35 UTC (permalink / raw)
  To: gcc-bugs



-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|4.5 regression: 16-byte     |[4.5 Regression] 16-byte
                   |aligned double is disallowed|aligned double is disallowed
                   |only in templates           |only in templates
   Target Milestone|---                         |4.5.0


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


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

* [Bug c++/42555] [4.5 Regression] 16-byte aligned double is disallowed only in templates
  2009-12-30 18:57 [Bug c++/42555] New: 4.5 regression: 16-byte aligned double is disallowed only in templates bredelin at ucla dot edu
                   ` (2 preceding siblings ...)
  2010-01-01 20:35 ` [Bug c++/42555] [4.5 Regression] " rguenth at gcc dot gnu dot org
@ 2010-01-01 23:48 ` hjl dot tools at gmail dot com
  2010-01-02 23:23 ` jason at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: hjl dot tools at gmail dot com @ 2010-01-01 23:48 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from hjl dot tools at gmail dot com  2010-01-01 23:48 -------
It is caused by revision 155246:

http://gcc.gnu.org/ml/gcc-cvs/2009-12/msg00390.html


-- 

hjl dot tools at gmail dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jason at redhat dot com


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


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

* [Bug c++/42555] [4.5 Regression] 16-byte aligned double is disallowed only in templates
  2009-12-30 18:57 [Bug c++/42555] New: 4.5 regression: 16-byte aligned double is disallowed only in templates bredelin at ucla dot edu
                   ` (3 preceding siblings ...)
  2010-01-01 23:48 ` hjl dot tools at gmail dot com
@ 2010-01-02 23:23 ` jason at gcc dot gnu dot org
  2010-01-02 23:48 ` hjl dot tools at gmail dot com
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu dot org @ 2010-01-02 23:23 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from jason at gcc dot gnu dot org  2010-01-02 23:23 -------
I can't reproduce this with the current 4.5 sources.


-- 


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


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

* [Bug c++/42555] [4.5 Regression] 16-byte aligned double is disallowed only in templates
  2009-12-30 18:57 [Bug c++/42555] New: 4.5 regression: 16-byte aligned double is disallowed only in templates bredelin at ucla dot edu
                   ` (4 preceding siblings ...)
  2010-01-02 23:23 ` jason at gcc dot gnu dot org
@ 2010-01-02 23:48 ` hjl dot tools at gmail dot com
  2010-01-04 17:04 ` jason at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: hjl dot tools at gmail dot com @ 2010-01-02 23:48 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from hjl dot tools at gmail dot com  2010-01-02 23:48 -------
(In reply to comment #4)
> I can't reproduce this with the current 4.5 sources.
> 

I still saw it with today's gcc 4.5. You need -O3 -msse2 on
Linux/x86 to see it.


-- 

hjl dot tools at gmail dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
   Last reconfirmed|0000-00-00 00:00:00         |2010-01-02 23:48:09
               date|                            |


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


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

* [Bug c++/42555] [4.5 Regression] 16-byte aligned double is disallowed only in templates
  2009-12-30 18:57 [Bug c++/42555] New: 4.5 regression: 16-byte aligned double is disallowed only in templates bredelin at ucla dot edu
                   ` (5 preceding siblings ...)
  2010-01-02 23:48 ` hjl dot tools at gmail dot com
@ 2010-01-04 17:04 ` jason at gcc dot gnu dot org
  2010-01-04 17:54 ` jason at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu dot org @ 2010-01-04 17:04 UTC (permalink / raw)
  To: gcc-bugs



-- 

jason at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |jason at gcc dot gnu dot org
                   |dot org                     |
             Status|NEW                         |ASSIGNED
   Last reconfirmed|2010-01-02 23:48:09         |2010-01-04 17:04:37
               date|                            |


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


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

* [Bug c++/42555] [4.5 Regression] 16-byte aligned double is disallowed only in templates
  2009-12-30 18:57 [Bug c++/42555] New: 4.5 regression: 16-byte aligned double is disallowed only in templates bredelin at ucla dot edu
                   ` (6 preceding siblings ...)
  2010-01-04 17:04 ` jason at gcc dot gnu dot org
@ 2010-01-04 17:54 ` jason at gcc dot gnu dot org
  2010-01-04 17:55 ` jason at gcc dot gnu dot org
  2010-01-07 22:24 ` hjl at gcc dot gnu dot org
  9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu dot org @ 2010-01-04 17:54 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from jason at gcc dot gnu dot org  2010-01-04 17:53 -------
Subject: Bug 42555

Author: jason
Date: Mon Jan  4 17:53:37 2010
New Revision: 155628

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=155628
Log:
        PR c++/42555
        * pt.c (tsubst_decl): Don't apply type attributes in place.

Added:
    trunk/gcc/testsuite/g++.dg/ext/attrib35.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/pt.c
    trunk/gcc/testsuite/ChangeLog


-- 


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


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

* [Bug c++/42555] [4.5 Regression] 16-byte aligned double is disallowed only in templates
  2009-12-30 18:57 [Bug c++/42555] New: 4.5 regression: 16-byte aligned double is disallowed only in templates bredelin at ucla dot edu
                   ` (7 preceding siblings ...)
  2010-01-04 17:54 ` jason at gcc dot gnu dot org
@ 2010-01-04 17:55 ` jason at gcc dot gnu dot org
  2010-01-07 22:24 ` hjl at gcc dot gnu dot org
  9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu dot org @ 2010-01-04 17:55 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #7 from jason at gcc dot gnu dot org  2010-01-04 17:55 -------
Fixed.


-- 

jason at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED


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


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

* [Bug c++/42555] [4.5 Regression] 16-byte aligned double is disallowed only in templates
  2009-12-30 18:57 [Bug c++/42555] New: 4.5 regression: 16-byte aligned double is disallowed only in templates bredelin at ucla dot edu
                   ` (8 preceding siblings ...)
  2010-01-04 17:55 ` jason at gcc dot gnu dot org
@ 2010-01-07 22:24 ` hjl at gcc dot gnu dot org
  9 siblings, 0 replies; 11+ messages in thread
From: hjl at gcc dot gnu dot org @ 2010-01-07 22:24 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #8 from hjl at gcc dot gnu dot org  2010-01-07 22:23 -------
Subject: Bug 42555

Author: hjl
Date: Thu Jan  7 22:22:32 2010
New Revision: 155713

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=155713
Log:
Backport tests from mainline

2010-01-07  H.J. Lu  <hongjiu.lu@intel.com>

        Backport from mainline:
        2010-01-06  Richard Guenther  <rguenther@suse.de>

        * gcc.c-torture/compile/pr42632.c: New testcase.

        2010-01-05  Martin Jambor  <mjambor@suse.cz>

        PR tree-optimization/42462
        * g++.dg/torture/pr42462.C: New test.

        2010-01-05  Jakub Jelinek  <jakub@redhat.com>

        PR tree-optimization/42508
        * g++.dg/opt/pr42508.C: New test.

        2010-01-04  Martin Jambor  <mjambor@suse.cz>

        PR tree-optimization/42398
        * gcc.c-torture/compile/pr42398.c: New test.

        2010-01-04  Jason Merrill  <jason@redhat.com>

        PR c++/42555
        * g++.dg/ext/attrib35.C: New.

        2010-01-01  Richard Guenther  <rguenther@suse.de>

        PR c/42570
        * gcc.c-torture/execute/pr42570.c: New testcase.

        2010-01-01  Richard Guenther  <rguenther@suse.de>

        PR middle-end/42559
        * gcc.c-torture/compile/pr42559.c: New testcase.

        2009-12-30  Joseph Myers  <joseph@codesourcery.com>

        PR c/42439
        * gcc.dg/bitfld-19.c: New test.

        2009-12-28  Jason Merrill  <jason@redhat.com>

        PR c++/42447
        * g++.dg/template/array21.C: New.

Added:
    branches/gcc-4_4-branch/gcc/testsuite/g++.dg/ext/attrib35.C
      - copied unchanged from r155711,
trunk/gcc/testsuite/g++.dg/ext/attrib35.C
    branches/gcc-4_4-branch/gcc/testsuite/g++.dg/opt/pr42508.C
      - copied unchanged from r155711, trunk/gcc/testsuite/g++.dg/opt/pr42508.C
    branches/gcc-4_4-branch/gcc/testsuite/g++.dg/template/array21.C
      - copied unchanged from r155710,
trunk/gcc/testsuite/g++.dg/template/array21.C
    branches/gcc-4_4-branch/gcc/testsuite/g++.dg/torture/pr42462.C
      - copied unchanged from r155711,
trunk/gcc/testsuite/g++.dg/torture/pr42462.C
    branches/gcc-4_4-branch/gcc/testsuite/gcc.c-torture/compile/pr42398.c
      - copied unchanged from r155711,
trunk/gcc/testsuite/gcc.c-torture/compile/pr42398.c
    branches/gcc-4_4-branch/gcc/testsuite/gcc.c-torture/compile/pr42559.c
      - copied unchanged from r155712,
trunk/gcc/testsuite/gcc.c-torture/compile/pr42559.c
    branches/gcc-4_4-branch/gcc/testsuite/gcc.c-torture/compile/pr42632.c
      - copied unchanged from r155710,
trunk/gcc/testsuite/gcc.c-torture/compile/pr42632.c
    branches/gcc-4_4-branch/gcc/testsuite/gcc.c-torture/execute/pr42570.c
      - copied unchanged from r155712,
trunk/gcc/testsuite/gcc.c-torture/execute/pr42570.c
    branches/gcc-4_4-branch/gcc/testsuite/gcc.dg/bitfld-19.c
      - copied unchanged from r155710, trunk/gcc/testsuite/gcc.dg/bitfld-19.c
Modified:
    branches/gcc-4_4-branch/gcc/testsuite/ChangeLog


-- 


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


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

end of thread, other threads:[~2010-01-07 22:24 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-12-30 18:57 [Bug c++/42555] New: 4.5 regression: 16-byte aligned double is disallowed only in templates bredelin at ucla dot edu
2009-12-30 19:00 ` [Bug c++/42555] " bredelin at ucla dot edu
2009-12-30 19:04 ` bredelin at ucla dot edu
2010-01-01 20:35 ` [Bug c++/42555] [4.5 Regression] " rguenth at gcc dot gnu dot org
2010-01-01 23:48 ` hjl dot tools at gmail dot com
2010-01-02 23:23 ` jason at gcc dot gnu dot org
2010-01-02 23:48 ` hjl dot tools at gmail dot com
2010-01-04 17:04 ` jason at gcc dot gnu dot org
2010-01-04 17:54 ` jason at gcc dot gnu dot org
2010-01-04 17:55 ` jason at gcc dot gnu dot org
2010-01-07 22:24 ` hjl 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).