[Bug c++/60595] New: Compiler error when computing default destructor thunk within virtual inheritance hierarchy

2014-03-19 Thread xgue...@tower-research.com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60595

Bug ID: 60595
   Summary: Compiler error when computing default destructor thunk
within virtual inheritance hierarchy
   Product: gcc
   Version: 4.8.2
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: xgue...@tower-research.com

Created attachment 32396
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=32396&action=edit
Repeatble source

- g++48 -std=c++11 -o bug bug.cpp
bug.cpp:20:11: internal compiler error: in use_thunk, at cp/method.c:338
   virtual ~B() = default;
   ^
0x5fc344 use_thunk(tree_node*, bool)
../../gcc-4.8.2/gcc/cp/method.c:338
0x60729c emit_associated_thunks(tree_node*)
../../gcc-4.8.2/gcc/cp/semantics.c:3774
0x607557 expand_or_defer_fn(tree_node*)
../../gcc-4.8.2/gcc/cp/semantics.c:3901
0x61ee6d maybe_clone_body(tree_node*)
../../gcc-4.8.2/gcc/cp/optimize.c:428
0x60734d expand_or_defer_fn_1(tree_node*)
../../gcc-4.8.2/gcc/cp/semantics.c:3825
0x607528 expand_or_defer_fn(tree_node*)
../../gcc-4.8.2/gcc/cp/semantics.c:3895
0x5fd4bf synthesize_method(tree_node*)
../../gcc-4.8.2/gcc/cp/method.c:809
0x5a9f9a mark_used(tree_node*)
../../gcc-4.8.2/gcc/cp/decl2.c:4677
0x556afc build_over_call
../../gcc-4.8.2/gcc/cp/call.c:7055
0x553fa8 build_new_method_call_1
../../gcc-4.8.2/gcc/cp/call.c:7715
0x553fa8 build_new_method_call(tree_node*, tree_node*, vec**, tree_node*, int, tree_node**, int)
../../gcc-4.8.2/gcc/cp/call.c:7785
0x55484e build_special_member_call(tree_node*, tree_node*, vec**, tree_node*, int, int)
../../gcc-4.8.2/gcc/cp/call.c:7352
0x5f4b7f expand_cleanup_for_base
../../gcc-4.8.2/gcc/cp/init.c:1217
0x5f90b1 expand_cleanup_for_base
../../gcc-4.8.2/gcc/cp/init.c:1112
0x5f90b1 emit_mem_initializers(tree_node*)
../../gcc-4.8.2/gcc/cp/init.c:1097
0x5fd856 synthesize_method(tree_node*)
../../gcc-4.8.2/gcc/cp/method.c:796
0x5a9f9a mark_used(tree_node*)
../../gcc-4.8.2/gcc/cp/decl2.c:4677
0x556afc build_over_call
../../gcc-4.8.2/gcc/cp/call.c:7055
0x553fa8 build_new_method_call_1
../../gcc-4.8.2/gcc/cp/call.c:7715
0x553fa8 build_new_method_call(tree_node*, tree_node*, vec**, tree_node*, int, tree_node**, int)
../../gcc-4.8.2/gcc/cp/call.c:7785
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.



- g++48 -v   
Using built-in specs.
COLLECT_GCC=/apps/infra/toolset/opteron_rhel6/gcc-4.8.2/bin/g++
COLLECT_LTO_WRAPPER=/apps/infra/toolset/opteron_rhel6/gcc-4.8.2/bin/../libexec/gcc/x86_64-unknown-linux-gnu/4.8.2/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: ../gcc-4.8.2/configure
--prefix=/spare/local/environbuild-infra/gcc/4.8.2
Thread model: posix
gcc version 4.8.2 (GCC)


[Bug c++/60182] New: g++ segfault within template expansion using "using" aliasing

2014-02-13 Thread xgue...@tower-research.com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60182

Bug ID: 60182
   Summary: g++ segfault within template expansion using "using"
aliasing
   Product: gcc
   Version: 4.8.2
Status: UNCONFIRMED
  Severity: major
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: xgue...@tower-research.com

Created attachment 32129
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=32129&action=edit
Code producing the issue

G++ segfault while passing a class member that has been declared using a
"using" alias to a templates function that uses templated type reduction.

[g++48 -std=c++11 -o test test.cpp]
test.cpp: In constructor ‘A::A(const string&)’:
test.cpp:28:25: internal compiler error: Segmentation fault
   doSomething(m_elements);
0x90661f crash_signal
../../gcc-4.8.2/gcc/toplev.c:332
0x58bedc unify
../../gcc-4.8.2/gcc/cp/pt.c:16580
0x58e9e1 unify_one_argument
../../gcc-4.8.2/gcc/cp/pt.c:15470
0x588dca type_unification_real
../../gcc-4.8.2/gcc/cp/pt.c:15542
0x58faf9 fn_type_unification(tree_node*, tree_node*, tree_node*, tree_node*
const*, unsigned int, tree_node*, unification_kind_t, int, bool)
../../gcc-4.8.2/gcc/cp/pt.c:15124
0x5516b1 add_template_candidate_real
../../gcc-4.8.2/gcc/cp/call.c:2925
0x54f0a1 add_template_candidate
../../gcc-4.8.2/gcc/cp/call.c:3022
0x54f0a1 add_candidates
../../gcc-4.8.2/gcc/cp/call.c:5023
0x5537fd perform_overload_resolution
../../gcc-4.8.2/gcc/cp/call.c:3817
0x55727a build_new_function_call(tree_node*, vec**, bool, int)
../../gcc-4.8.2/gcc/cp/call.c:3894
0x606911 finish_call_expr(tree_node*, vec**, bool,
bool, int)
../../gcc-4.8.2/gcc/cp/semantics.c:2231
0x5c4d5a cp_parser_postfix_expression
../../gcc-4.8.2/gcc/cp/parser.c:5862
0x5c6edd cp_parser_unary_expression
../../gcc-4.8.2/gcc/cp/parser.c:6736
0x5c7a0f cp_parser_binary_expression
../../gcc-4.8.2/gcc/cp/parser.c:7428
0x5c7ebf cp_parser_assignment_expression
../../gcc-4.8.2/gcc/cp/parser.c:7664
0x5c9ab3 cp_parser_expression
../../gcc-4.8.2/gcc/cp/parser.c:7826
0x5ca21c cp_parser_expression
../../gcc-4.8.2/gcc/cp/parser.c:7865
0x5ca21c cp_parser_expression_statement
../../gcc-4.8.2/gcc/cp/parser.c:9127
0x5c13c7 cp_parser_statement
../../gcc-4.8.2/gcc/cp/parser.c:8979
0x5c259e cp_parser_statement_seq_opt
../../gcc-4.8.2/gcc/cp/parser.c:9245
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.