This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/60820] New: ice in ctor_for_folding, at varpool.c:291


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

            Bug ID: 60820
           Summary: ice in ctor_for_folding, at varpool.c:291
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: mliska at suse dot cz

I test gcc 4.9 on my x86_64 gentoo machine and ICE is encountered in
'net-misc/nx' package:

lto1: internal compiler error: in ctor_for_folding, at varpool.c:305
0xb4b0b6 ctor_for_folding(tree_node*)
    ../../gcc/varpool.c:292
0xb4b448 dump_varpool_node(_IO_FILE*, varpool_node*)
    ../../gcc/varpool.c:211
0x5bba6a dump_symtab(_IO_FILE*)
    ../../gcc/symtab.c:707
0x546084 do_whole_program_analysis
    ../../gcc/lto/lto.c:3248
0x546084 lto_main()
    ../../gcc/lto/lto.c:3422

decl:
 <var_decl 0x7f574898be40 in6addr_any
    type <record_type 0x7f57488e4690 in6_addr readonly TI
        size <integer_cst 0x7f5748fc60a0 constant 128>
        unit size <integer_cst 0x7f5748fc60c0 constant 16>
        align 32 symtab 0 alias set 0 canonical type 0x7f57488e4dc8
        fields <field_decl 0x7f57488ed980 __in6_u type <union_type
0x7f57488e4d20>
            TI file /usr/include/netinet/in.h line 206 col 9 size <integer_cst
0x7f5748fc60a0 128> unit size <integer_cst 0x7f5748fc60c0 16>
            align 32 offset_align 128
            offset <integer_cst 0x7f5748fc6060 constant 0>
            bit offset <integer_cst 0x7f5748fc60e0 constant 0> context
<record_type 0x7f57488e4dc8 in6_addr>> context <translation_unit_decl
0x7f57488ebb80 D.33269>
        pointer_to_this <pointer_type 0x7f57488e4738>>
    readonly public static weak TI file /usr/include/netinet/in.h line 214 col
30 size <integer_cst 0x7f5748fc60a0 128> unit size <integer_cst 0x7f5748fc60c0
16>
    align 32 context <translation_unit_decl 0x7f5748977ac8 D.36198> attributes
<tree_list 0x7f5748993190> initial <constructor 0x7f5748974798>>

DECL_INITIAL(decl):
 <constructor 0x7f5748974798
    type <record_type 0x7f57488e4690 in6_addr readonly TI
        size <integer_cst 0x7f5748fc60a0 constant 128>
        unit size <integer_cst 0x7f5748fc60c0 constant 16>
        align 32 symtab 0 alias set 0 canonical type 0x7f57488e4dc8
        fields <field_decl 0x7f57488ed980 __in6_u type <union_type
0x7f57488e4d20>
            TI file /usr/include/netinet/in.h line 206 col 9 size <integer_cst
0x7f5748fc60a0 128> unit size <integer_cst 0x7f5748fc60c0 16>
            align 32 offset_align 128
            offset <integer_cst 0x7f5748fc6060 constant 0>
            bit offset <integer_cst 0x7f5748fc60e0 constant 0> context
<record_type 0x7f57488e4dc8 in6_addr>> context <translation_unit_decl
0x7f57488ebb80 D.33269>
        pointer_to_this <pointer_type 0x7f57488e4738>>
    constant static lngt 1 idx <field_decl 0x7f57488ed980 __in6_u>
    val <constructor 0x7f5748974768
        type <union_type 0x7f57488e4d20 TI size <integer_cst 0x7f5748fc60a0
128> unit size <integer_cst 0x7f5748fc60c0 16>
            align 32 symtab 0 alias set 0 canonical type 0x7f57488e4d20 fields
<field_decl 0x7f57488ed7b8 __u6_addr8> context <translation_unit_decl
0x7f57488ebb80 D.33269>
            chain <type_decl 0x7f57488e2cf0 D.33550>>
        constant static lngt 1
        idx <field_decl 0x7f57488ed7b8 __u6_addr8 type <array_type
0x7f57488e4b28>
            TI file /usr/include/netinet/in.h line 201 col 10 size <integer_cst
0x7f5748fc60a0 128> unit size <integer_cst 0x7f5748fc60c0 16>
            align 8 offset_align 128 offset <integer_cst 0x7f5748fc6060 0> bit
offset <integer_cst 0x7f5748fc60e0 0> context <union_type 0x7f57488e4d20> chain
<field_decl 0x7f57488ed850 __u6_addr16>>
        val <constructor 0x7f5748974750 type <array_type 0x7f57488e4b28>
            constant static lngt 16 idx <integer_cst 0x7f5748fc60e0 0>
            val <integer_cst 0x7f5748fc6220 constant 0>
            idx <integer_cst 0x7f5748fc6680 constant 1> val <integer_cst
0x7f5748fc6220 0>
            idx <integer_cst 0x7f57490695c0 constant 2> val <integer_cst
0x7f5748fc6220 0>
            idx <integer_cst 0x7f5749139040 constant 3> val <integer_cst
0x7f5748fc6220 0>
            idx <integer_cst 0x7f57490695a0 constant 4> val <integer_cst
0x7f5748fc6220 0>
            idx <integer_cst 0x7f5749139180 constant 5> val <integer_cst
0x7f5748fc6220 0>
            idx <integer_cst 0x7f5749139240 constant 6> val <integer_cst
0x7f5748fc6220 0>
            idx <integer_cst 0x7f57491392e0 constant 7> val <integer_cst
0x7f5748fc6220 0>
            idx <integer_cst 0x7f5748fc61e0 constant 8> val <integer_cst
0x7f5748fc6220 0>
            idx <integer_cst 0x7f5749139400 constant 9> val <integer_cst
0x7f5748fc6220 0>
            idx <integer_cst 0x7f57491394a0 constant 10> val <integer_cst
0x7f5748fc6220 0>
            idx <integer_cst 0x7f5749139520 constant 11> val <integer_cst
0x7f5748fc6220 0>
            idx <integer_cst 0x7f57491395a0 constant 12> val <integer_cst
0x7f5748fc6220 0>
            idx <integer_cst 0x7f5749139640 constant 13> val <integer_cst
0x7f5748fc6220 0>
            idx <integer_cst 0x7f57491396c0 constant 14> val <integer_cst
0x7f5748fc6220 0>
            idx <integer_cst 0x7f5749139740 constant 15> val <integer_cst
0x7f5748fc6220 0>>>>

tail -n7 nxagent.wpa.000i.cgraph:

in6addr_any/8509 (in6addr_any) @0x7f574517de38
  Type: variable definition analyzed alias
  Visibility: externally_visible prevailing_def public weak
  References: local_in6addr_any/8508 (alias)
  Referring: _XSERVTransSocketINETCreateListener/8525
(read)_FontTransSocketINETCreateListener/63329 (read)
  Read from file: os/libos.a
  Availability: available
  Varpool flags: initialized read-only

cgraph dump:
https://drive.google.com/file/d/0B0pisUJ80pO1YjVsOU15eWJ5c1k/edit?usp=sharing

source code snippet:
/*
 * This provides compatibility for apps linked against system libraries
 * that don't have IPv6 support.
 */
#if defined(IPv6) && defined(AF_INET6)
static const struct in6_addr local_in6addr_any = IN6ADDR_ANY_INIT;
#pragma weak in6addr_any = local_in6addr_any
#ifndef __USLC__
#pragma weak getaddrinfo
#endif
static int haveIPv6 = 1;
#endif


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]