public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/60642] New: abi_tag attribute doesn't work on explicit specializations of class templates
@ 2014-03-25  2:21 lukeallardyce at gmail dot com
  2014-03-25 18:41 ` [Bug c++/60642] Unclear diagnostic with invalid use of abi_tag attribute on explicit instantiation redi at gcc dot gnu.org
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: lukeallardyce at gmail dot com @ 2014-03-25  2:21 UTC (permalink / raw)
  To: gcc-bugs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="UTF-8", Size: 4341 bytes --]

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

            Bug ID: 60642
           Summary: abi_tag attribute doesn't work on explicit
                    specializations of class templates
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: lukeallardyce at gmail dot com

This seems to not be working again in trunk?
(http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55275)

template<typename T>
class __attribute((abi_tag("foo"))) test{  };

template class __attribute((abi_tag("foo"))) test<int>;

int main() { }

abi_test.cpp:4:46: error: redeclaration of ‘class test<int>’ adds abi tag "foo"
 template class __attribute((abi_tag("foo"))) test<int>;
                                              ^
abi_test.cpp:2:37: note: previous declaration here
 class __attribute((abi_tag("foo"))) test{  };
>From gcc-bugs-return-447344-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Mar 25 03:26:57 2014
Return-Path: <gcc-bugs-return-447344-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 1039 invoked by alias); 25 Mar 2014 03:26:56 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 1022 invoked by uid 48); 25 Mar 2014 03:26:51 -0000
From: "hongxu.jia at windriver dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug debug/60643] New: ICE with -O1 and -g on mips (internal compiler error: in dwarf2out_var_location, at dwarf2out.c:20810)
Date: Tue, 25 Mar 2014 03:26:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: debug
X-Bugzilla-Version: 4.8.2
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: hongxu.jia at windriver dot com
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter attachments.created
Message-ID: <bug-60643-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2014-03/txt/msg02213.txt.bz2
Content-length: 1455

http://gcc.gnu.org/bugzilla/show_bug.cgi?id`643

            Bug ID: 60643
           Summary: ICE with -O1 and -g on mips (internal compiler error:
                    in dwarf2out_var_location, at dwarf2out.c:20810)
           Product: gcc
           Version: 4.8.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: debug
          Assignee: unassigned at gcc dot gnu.org
          Reporter: hongxu.jia at windriver dot com

Created attachment 32440
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id2440&actioníit
the config.log of mips-poky-linux-gcc

I have hit a ICE and could reduce it to the following minimal example:

1. Only the size of array assigned with 2 caused the issue:
$ cat > mipgcc-test.c << END

#include <stdio.h>

#define ARRAY_SIZE_MAX  2

int main (int argc, char **argv)
{
        char *pStrArry[ARRAY_SIZE_MAX] = {"hello"};
        int i = 0;

        while(pStrArry[i] && i<ARRAY_SIZE_MAX)
        {
                printf("%s\n", pStrArry[i]);
                i++;
        }

        return 0;
}

END

2. Only -O1 and -g on mips caused the issue:
$ mips-poky-linux-gcc -O1 -g -o mipgcc-test mipgcc-test.c
mipgcc-test.c: In function 'main':
mipgcc-test.c:18:1: internal compiler error: in dwarf2out_var_location, at
dwarf2out.c:20810
 }
 ^
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions


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

end of thread, other threads:[~2014-04-01 19:20 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-03-25  2:21 [Bug c++/60642] New: abi_tag attribute doesn't work on explicit specializations of class templates lukeallardyce at gmail dot com
2014-03-25 18:41 ` [Bug c++/60642] Unclear diagnostic with invalid use of abi_tag attribute on explicit instantiation redi at gcc dot gnu.org
2014-03-25 23:51 ` lukeallardyce at gmail dot com
2014-03-26  2:52 ` lukeallardyce at gmail dot com
2014-03-26 10:53 ` redi at gcc dot gnu.org
2014-03-27 21:16 ` jason at gcc dot gnu.org
2014-04-01 17:50 ` jason at gcc dot gnu.org
2014-04-01 19:20 ` jason at gcc dot gnu.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).