1. 14 Jan, 2015 33 commits
  2. 13 Jan, 2015 7 commits
    • configure.host: Remove extra brackets for sh. · b1479ae3
      * libffi/configure.host: Remove extra brackets for sh.
      
      From-SVN: r219565
      Kaz Kojima committed
    • jit: New API entrypoint: gcc_jit_context_dump_reproducer_to_file · 86d0ac88
      gcc/jit/ChangeLog:
      	* docs/cp/topics/contexts.rst (Debugging): Add
      	gccjit::context::dump_reproducer_to_file.
      	* docs/internals/index.rst (Design notes): New section,
      	discussing input validation and
      	gcc_jit_context_dump_reproducer_to_file.
      	* docs/topics/contexts.rst (Debugging): Add
      	gcc_jit_context_dump_reproducer_to_file.
      	* docs/_build/texinfo/libgccjit.texi: Regenerate.
      	* jit-common.h (gcc::jit::dump::get_context): New accessor.
      	* jit-recording.c: Include "hash-map.h".
      	Within namespace ::gcc::jit...
      	(dump::write): Flush each line.
      	(dump::make_location): Pass false for new param "created_by_user".
      	(class allocator): New class.
      	(allocator::~allocator): New function.
      	(allocator::xstrdup_printf): New function.
      	(allocator::xstrdup_printf_va): New function.
      	(class reproducer): New subclass of dump.
      	(reproducer::reproducer): New function.
      	(reproducer::write_params): New function.
      	(reproducer::write_args): New function.
      	(reproducer::make_identifier): New function.
      	(reproducer::make_tmp_identifier): New function.
      	(reproducer::get_identifier): New pair of functions.
      	(reproducer::get_identifier_as_rvalue): New function.
      	(reproducer::get_identifier_as_lvalue): New function.
      	(reproducer::get_identifier_as_type): New function.
      	(reproducer::xstrdup_printf): New function.
      	(recording::context::context): Initialize m_toplevel_ctxt.
      	(recording::context::new_location): Add param created_by_user.
      	(str_option_reproducer_strings): New table of strings.
      	(int_option_reproducer_strings): Likewise.
      	(bool_option_reproducer_strings): Likewise.
      	(get_type_enum_strings): Likewise.
      	(names_of_function_kinds): Likewise.
      	(global_kind_reproducer_strings): Likewise.
      	(unary_op_reproducer_strings): Likewise.
      	(binary_op_reproducer_strings): Likewise.
      	(comparison_reproducer_strings): Likewise.
      	Within namespace ::gcc::jit::recording::...
      	(context::dump_reproducer_to_file): New function.
      	(string::write_reproducer): Likewise.
      	(location::write_reproducer): Likewise.
      	(type::access_as_type): Likewise.
      	(memento_of_get_type::write_reproducer): Likewise.
      	(memento_of_get_pointer::write_reproducer): Likewise.
      	(memento_of_get_const::write_reproducer): Likewise.
      	(memento_of_get_volatile::write_reproducer): Likewise.
      	(array_type::write_reproducer): Likewise.
      	(function_type::write_reproducer): Likewise.
      	(function_type::write_deferred_reproducer): Likewise.
      	(field::write_reproducer): Likewise.
      	(struct_::access_as_type): Likewise.
      	(struct_::write_reproducer): Likewise.
      	(union_::write_reproducer): Likewise.
      	(fields::write_reproducer): Likewise.
      	(rvalue::access_as_rvalue): Likewise.
      	(lvalue::access_as_rvalue): Likewise.
      	(lvalue::access_as_lvalue): Likewise.
      	(param::access_as_rvalue): Likewise.
      	(param::access_as_lvalue): Likewise.
      	(param::write_reproducer): Likewise.
      	(function::write_reproducer): Likewise.
      	(block::write_reproducer): Likewise.
      	(global::write_reproducer): Likewise.
      	(memento_of_new_rvalue_from_const <int>::write_reproducer):
      	Likewise.
      	(memento_of_new_rvalue_from_const <long>::write_reproducer):
      	Likewise.
      	(memento_of_new_rvalue_from_const <double>::write_reproducer):
      	Likewise.
      	(memento_of_new_rvalue_from_const <void *>::write_reproducer):
      	Likewise.
      	(memento_of_new_string_literal::write_reproducer): Likewise.
      	(unary_op::write_reproducer): Likewise.
      	(binary_op::write_reproducer): Likewise.
      	(comparison::write_reproducer): Likewise.
      	(cast::write_reproducer): Likewise.
      	(call::write_reproducer): Likewise.
      	(call_through_ptr::write_reproducer): Likewise.
      	(array_access::write_reproducer): Likewise.
      	(access_field_of_lvalue::write_reproducer): Likewise.
      	(access_field_rvalue::write_reproducer): Likewise.
      	(dereference_field_rvalue::write_reproducer): Likewise.
      	(dereference_rvalue::write_reproducer): Likewise.
      	(get_address_of_lvalue::write_reproducer): Likewise.
      	(local::write_reproducer): Likewise.
      	(eval::write_reproducer): Likewise.
      	(assignment::write_reproducer): Likewise.
      	(assignment_op::write_reproducer): Likewise.
      	(comment::write_reproducer): Likewise.
      	(conditional::write_reproducer): Likewise.
      	(jump::write_reproducer): Likewise.
      	(return_::write_reproducer): Likewise.
      	* jit-recording.h (gcc::jit::reproducer): New forward declararion.
      	Within namespace ::gcc::jit::recording::...
      	(context::new_location): Add "created_by_user" param.
      	(context::dump_reproducer_to_file): New method.
      	(context::m_toplevel_ctxt): New field.
      	(memento::write_reproducer): New pure virtual function.
      	(memento::dyn_cast_location): New virtual function.
      	(string::write_reproducer):
      	(location::location): Add "created_by_user" param.
      	(location::dyn_cast_location): New function.
      	(location::created_by_user): New accessor.
      	(location::write_reproducer): New function.
      	(location::m_created_by_user): New field.
      	(type::access_as_type): New virtual function.
      	(location::write_reproducer): Likewise.
      	(type::access_as_type): Likewise.
      	(memento_of_get_type::write_reproducer): Likewise.
      	(memento_of_get_pointer::write_reproducer): Likewise.
      	(memento_of_get_const::write_reproducer): Likewise.
      	(memento_of_get_volatile::write_reproducer): Likewise.
      	(array_type::write_reproducer): Likewise.
      	(function_type::write_reproducer): Likewise.
      	(function_type::write_deferred_reproducer): Likewise.
      	(field::write_reproducer): Likewise.
      	(struct_::access_as_type): Likewise.
      	(struct_::write_reproducer): Likewise.
      	(union_::write_reproducer): Likewise.
      	(union_::m_fields): Remove stray unused field.
      	(fields::length): New accessor.
      	(fields::get_field): New accessor.
      	(fields::write_reproducer): New function.
      	(rvalue::access_as_rvalue): Likewise.
      	(lvalue::access_as_rvalue): Likewise.
      	(lvalue::access_as_lvalue): Likewise.
      	(param::access_as_rvalue): Likewise.
      	(param::access_as_lvalue): Likewise.
      	(param::write_reproducer): Likewise.
      	(function::write_reproducer): Likewise.
      	(block::write_reproducer): Likewise.
      	(global::write_reproducer): Likewise.
      	(memento_of_new_rvalue_from_const <HOST_TYPE>::write_reproducer):
      	Likewise.
      	(memento_of_new_string_literal::write_reproducer): Likewise.
      	(unary_op::write_reproducer): Likewise.
      	(binary_op::write_reproducer): Likewise.
      	(comparison::write_reproducer): Likewise.
      	(cast::write_reproducer): Likewise.
      	(call::write_reproducer): Likewise.
      	(call_through_ptr::write_reproducer): Likewise.
      	(array_access::write_reproducer): Likewise.
      	(access_field_of_lvalue::write_reproducer): Likewise.
      	(access_field_rvalue::write_reproducer): Likewise.
      	(dereference_field_rvalue::write_reproducer): Likewise.
      	(dereference_rvalue::write_reproducer): Likewise.
      	(get_address_of_lvalue::write_reproducer): Likewise.
      	(local::write_reproducer): Likewise.
      	(eval::write_reproducer): Likewise.
      	(assignment::write_reproducer): Likewise.
      	(assignment_op::write_reproducer): Likewise.
      	(comment::write_reproducer): Likewise.
      	(conditional::write_reproducer): Likewise.
      	(jump::write_reproducer): Likewise.
      	(return_::write_reproducer): Likewise.
      	* libgccjit++.h (gccjit::context::dump_reproducer_to_file): New.
      	* libgccjit.c (gcc_jit_context_new_location): Pass "true" as
      	param "created_by_user".
      	(gcc_jit_context_dump_reproducer_to_file): New API entrypoint.
      	* libgccjit.h (gcc_jit_context_dump_reproducer_to_file): New API
      	entrypoint.
      	* libgccjit.map (gcc_jit_context_dump_reproducer_to_file): New API
      	entrypoint.
      
      gcc/testsuite/ChangeLog:
      	* jit.dg/harness.h (set_up_logging): Move string concatenation
      	into...
      	(concat_strings): New function.
      	(dump_reproducer): New function.
      	(test_jit): Call dump_reproducer.
      	* jit.dg/jit.exp (is_testcase_meant_to_generate_a_reproducer): New
      	function.
      	(jit-dg-test): Delete any generated reproducer from previous runs.
      	Verify that a generated reproducer was created, and verify that it
      	compiles.
      	* jit.dg/test-nested-contexts.c (main): Call
      	gcc_jit_context_dump_reproducer_to_file.
      
      From-SVN: r219564
      David Malcolm committed
    • Add dg-require-profiling to gcc.dg/aru-2.c · 9c80f919
      	* gcc.dg/aru-2.c: Add dg-require-profiling.
      
      From-SVN: r219561
      H.J. Lu committed
    • Check if -pg links in check_profiling_available · f263fe40
      	* lib/target-supports.exp (check_profiling_available): Check if
      	-pg links.
      
      From-SVN: r219560
      H.J. Lu committed
    • re PR c++/64356 (Some constexpr expressions not recognized as constexpr) · caee690e
      	PR c++/64356
      	PR libstdc++/58777
      	* constexpr.c (cxx_eval_binary_expression): Don't VERIFY_CONSTANT
      	pointer expressions.
      	(cxx_eval_increment_expression): Likewise.
      
      From-SVN: r219559
      Jason Merrill committed
    • re PR c++/64514 (Error in template instantiation in GCC 4.9, works fine in GCC 4.8) · 7c368fb2
      	PR c++/64514
      	* pt.c (coerce_template_parameter_pack): Return NULL for a
      	zero-length fixed parameter pack with a pack expansion arg.
      
      From-SVN: r219558
      Jason Merrill committed
    • re PR c++/64520 (ICE with std::initializer_list) · 8f413ae2
      	PR c++/64520
      	* pt.c (unify): Don't try to deduce to std::initializer_list<T...>.
      
      From-SVN: r219557
      Jason Merrill committed