s390.md: Added agen condition to operand forwarding bypasses.
2009-10-20 Wolfgang Gellerich <gellerich@de.ibm.com>
* config/s390/s390.md: Added agen condition to operand
forwarding bypasses.
Added bypass for early address generation use of int results.
Updated comments.
* charset.c (cpp_init_iconv): Initialize utf8_cset_desc.
(_cpp_destroy_iconv): Destroy utf8_cset_desc, char16_cset_desc
and char32_cset_desc.
(converter_for_type): Handle CPP_UTF8STRING.
(cpp_interpret_string): Handle CPP_UTF8STRING and raw-strings.
* directives.c (get__Pragma_string): Handle CPP_UTF8STRING.
(parse_include): Reject raw strings.
* include/cpplib.h (CPP_UTF8STRING): New token type.
* internal.h (struct cpp_reader): Add utf8_cset_desc field.
* lex.c (lex_raw_string): New function.
(lex_string): Handle u8 string literals, call lex_raw_string
for raw string literals.
(_cpp_lex_direct): Call lex_string even for u8" and {,u,U,L,u8}R"
sequences.
* macro.c (stringify_arg): Handle CPP_UTF8STRING.
* c-common.c (c_parse_error): Handle CPP_UTF8STRING.
* c-lex.c (c_lex_with_flags): Likewise. Test C_LEX_STRING_NO_JOIN
instead of C_LEX_RAW_STRINGS.
(lex_string): Handle CPP_UTF8STRING.
* c-parser.c (c_parser_postfix_expression): Likewise.
* c-pragma.h (C_LEX_RAW_STRINGS): Rename to ...
(C_LEX_STRING_NO_JOIN): ... this.
* parser.c (cp_lexer_print_token, cp_parser_is_string_literal,
cp_parser_string_literal, cp_parser_primary_expression): Likewise.
(cp_lexer_get_preprocessor_token): Use C_LEX_STRING_JOIN instead
of C_LEX_RAW_STRINGS.
* gcc.dg/raw-string-1.c: New test.
* gcc.dg/raw-string-2.c: New test.
* gcc.dg/raw-string-3.c: New test.
* gcc.dg/raw-string-4.c: New test.
* gcc.dg/raw-string-5.c: New test.
* gcc.dg/raw-string-6.c: New test.
* gcc.dg/raw-string-7.c: New test.
* gcc.dg/utf8-1.c: New test.
* gcc.dg/utf8-2.c: New test.
* gcc.dg/utf-badconcat2.c: New test.
* gcc.dg/utf-dflt2.c: New test.
* gcc.dg/cpp/include6.c: New test.
* g++.dg/ext/raw-string-1.C: New test.
* g++.dg/ext/raw-string-2.C: New test.
* g++.dg/ext/raw-string-3.C: New test.
* g++.dg/ext/raw-string-4.C: New test.
* g++.dg/ext/raw-string-5.C: New test.
* g++.dg/ext/raw-string-6.C: New test.
* g++.dg/ext/raw-string-7.C: New test.
* g++.dg/ext/utf8-1.C: New test.
* g++.dg/ext/utf8-2.C: New test.
* g++.dg/ext/utf-badconcat2.C: New test.
* g++.dg/ext/utf-dflt2.C: New test.
* gimple-low.c (struct lower_data): Add cannot_fallthru field.
(lower_stmt) <GIMPLE_BIND>: Add comment.
<GIMPLE_COND, GIMPLE_GOTO, GIMPLE_SWITCH>: Set cannot_fallthru to true
and return.
<GIMPLE_RETURN>: Remove the statement if cannot_fallthru is set.
Otherwise lower it and set cannot_fallthru to true.
<GIMPLE_TRY>: Update cannot_fallthru for GIMPLE_TRY_FINALLY and return.
<GIMPLE_CATCH, GIMPLE_EH_FILTER>; Set cannot_fallthru to false.
<GIMPLE_CALL>: Set cannot_fallthru to false for BUILT_IN_SETJMP and
to true for a noreturn call. Do not remove statements.
<GIMPLE_OMP_PARALLEL, GIMPLE_OMP_TASK>: Set cannot_fallthru to false.
Set cannot_fallthru to false on function exit.
(gimple_stmt_may_fallthru) <GIMPLE_SWITCH>: Really return false.
<GIMPLE_ASSIGN>: Remove.
Andy Hutchinson [Sat, 17 Oct 2009 22:42:17 +0000 (22:42 +0000)]
re PR middle-end/41738 (optabs expands rotate using wrong mode)
2009-10-17 Andy Hutchinson <hutchinsonandy@gcc.gnu.org>
PR middle-end/41738
* optabs.c (expand_binop): Make mode of shift count expression mode of shift count not target.
Remove indent nit.
Eric Botcazou [Sat, 17 Oct 2009 22:21:24 +0000 (22:21 +0000)]
tree-nested.c (convert_nonlocal_reference_stmt): New case.
* tree-nested.c (convert_nonlocal_reference_stmt) <GIMPLE_COND>: New
case. Force using values to replace references within the statement.
(convert_local_reference_stmt): Likewise.
Andy Hutchinson [Sat, 17 Oct 2009 22:15:45 +0000 (22:15 +0000)]
avr.md (*movqi): Add zero as equally preferable constraint as general register.
2009-10-17 Andy Hutchinson <hutchinsonandy@aim.com>
* config/avr.md (*movqi): Add zero as equally preferable constraint as general register.
(*movhi): Ditto.
Janus Weil [Sat, 17 Oct 2009 18:09:25 +0000 (20:09 +0200)]
re PR fortran/41608 ([OOP] ICE with CLASS and invalid code)
2009-10-17 Janus Weil <janus@gcc.gnu.org>
Paul Thomas <pault@gcc.gnu.org>
PR fortran/41608
* decl.c (gfc_match_data_decl): Add BT_CLASS for undefined type
and empty type errors.
* parse.c (gfc_build_block_ns): Only set recursive if parent ns
has a proc_name.
PR fortran/41629
PR fortran/41618
PR fortran/41587
* gfortran.h : Add class_ok bitfield to symbol_attr.
* decl.c (build_sym): Set attr.class_ok if dummy, pointer or
allocatable.
(build_struct): Use gfc_try 't' to carry errors past the call
to encapsulate_class_symbol.
(attr_decl1): For a CLASS object, apply the new attribute to
the data component.
* match.c (gfc_match_select_type): Set attr.class_ok for an
assigned selector.
* resolve.c (resolve_fl_variable_derived): Check a CLASS object
is dummy, pointer or allocatable by testing the class_ok and
the use_assoc attribute.
2009-10-17 Janus Weil <janus@gcc.gnu.org>
Paul Thomas <pault@gcc.gnu.org>
PR fortran/41629
* gfortran.dg/class_6.f90: New test.
PR fortran/41608
PR fortran/41587
* gfortran.dg/class_7.f90: New test.
PR fortran/41618
* gfortran.dg/class_8.f90: New test.
Co-Authored-By: Paul Thomas <pault@gcc.gnu.org>
From-SVN: r152955
Eric Botcazou [Sat, 17 Oct 2009 11:17:27 +0000 (11:17 +0000)]
utils.c (convert): When converting to a padded type with an inner type of self-referential size...
* gcc-interface/utils.c (convert): When converting to a padded type
with an inner type of self-referential size, pad the expression before
doing the unchecked conversion.
Anatoly Sokolov [Sat, 17 Oct 2009 10:46:18 +0000 (14:46 +0400)]
targhooks.c (default_libcall_value): Don't use LIBCALL_VALUE macro if not defined.
* targhooks.c (default_libcall_value): Don't use LIBCALL_VALUE macro
if not defined. Change type of second argument to const_rtx.
(default_function_value): Call gcc_unreachable if FUNCTION_VALUE
macro not defined.
* targhooks.h (default_libcall_value): Update prototype.
* target.h (struct gcc_target): Change type of second argument of
libcall_value to const_rtx.
* config/arm/arm.c (arm_libcall_value): Change type of second argument
to const_rtx.
(arm_libcall_uses_aapcs_base): Change type of argument to const_rtx.
* doc/tm.texi (TARGET_LIBCALL_VALUE): Revise documentation.
Ralf Wildenhues [Sat, 17 Oct 2009 07:34:47 +0000 (07:34 +0000)]
Fix libgomp without --enable-languages=fortran.
libgomp/:
PR libgomp/41418
* configure.ac: Set FC to "no" if $GFORTRAN starts with "no"
or a hyphen (happens with fortran language disabled).
* configure: Regenerate.
Jason Merrill [Sat, 17 Oct 2009 06:11:08 +0000 (02:11 -0400)]
re PR c++/38798 ([c++0x] Trouble with struct/class/enum keyword in late return types)
PR c++/38798
* parser.c (CP_PARSER_FLAGS_NO_TYPE_DEFINITIONS): New.
(cp_parser_type_specifier): Don't try to parse a class-specifier
or enum-specifier in that case.
(cp_parser_trailing_type_id): New.
(cp_parser_late_return_type_opt): Call it.
(cp_parser_type_id_1): Add is_trailing_return parm.
(cp_parser_type_specifier_seq): Likewise.
* lto-symtab.c (merge_incomplete_and_complete_type): Remove.
(maybe_merge_incomplete_and_complete_type): Likewise.
(lto_symtab_merge): Do not call them. Do not warn for
complete vs. incomplete compatible types.
(lto_symtab_merge_decls_2): Simplify.
* gimple.c (gimple_force_type_merge): Remove.
(gimple_types_compatible_p): Make it static.
* gimple.h (gimple_force_type_merge): Remove.
(gimple_types_compatible_p): Likewise.
2009-10-16 Rafael Avila de Espindola <espindola@google.com>
* lto-plugin.c (message): New variable.
(check): New function.
(parse_table_entry, translate, write_resolution,add_output_files,
exec_lto_wrapper,claim_file_handler, onload): Use check instead of
assert.
(cleanup_handler): Use check instead of assert. Remove the arguments
file if it exists.
Richard Guenther [Fri, 16 Oct 2009 11:45:55 +0000 (11:45 +0000)]
gimple.c (iterative_hash_gimple_type): For integer types also hash their minimum and maximum values and the string flag.
2009-10-16 Richard Guenther <rguenther@suse.de>
* gimple.c (iterative_hash_gimple_type): For integer types
also hash their minimum and maximum values and the string flag.
For array types hash their domain and the string flag.
Richard Guenther [Fri, 16 Oct 2009 11:44:46 +0000 (11:44 +0000)]
gimple.c (gimple_types_compatible_p): Restrict completing types to record or unions.
2009-10-16 Richard Guenther <rguenther@suse.de>
* gimple.c (gimple_types_compatible_p): Restrict completing
types to record or unions. Simplify completion.
Do not merge records or unions with different
TYPE_STRUCTURAL_EQUALITY_P tag.
(iterative_hash_gimple_type): Restrict non-recursing into
pointer targets for records and unions.
Jakub Jelinek [Fri, 16 Oct 2009 10:43:18 +0000 (12:43 +0200)]
re PR debug/41717 (internal compiler error: in expand_debug_expr)
PR debug/41717
* cfgexpand.c (expand_debug_expr): Handle CONJ_EXPR.
* dwarf2out.c (mem_loc_descriptor): Don't handle
POST_INT/POST_DEC/POST_MODIFY like SUBREG. For SUBREG
punt if it is not lowpart subreg or if inner mode isn't
MODE_INT.
Benjamin Kosnik [Fri, 16 Oct 2009 07:47:33 +0000 (07:47 +0000)]
re PR libstdc++/40654 ([C++0x] atomic.cc: 'd' is used uninitialized warning)
2009-10-15 Benjamin Kosnik <bkoz@redhat.com>
PR libstdc++/40654
PR libstdc++/40826
* src/atomic.cc (atomic_flag_test_and_set_explicit): Add
static_cast from base to derived.
(atomic_flag_clear_explicit): Same.
* include/bits/atomic_2.h (__atomic2::atomic_flag): Public derivation.
Remove value type constructor.
* include/bits/atomic_0.h (__atomic0::atomic_flag): Same.
* include/std/future (_Future_state): Use ATOMIC_FLAG_INIT to
initialized the atomic_flag member.
Paul Thomas [Fri, 16 Oct 2009 06:07:09 +0000 (06:07 +0000)]
re PR fortran/41648 ([OOP] Type-bound procedures refused)
2009-10-16 Paul Thomas <pault@gcc.gnu.org>
PR fortran/41648
PR fortran/41656
* trans-expr.c (select_class_proc): Convert the expression for the
vindex, carried on the first member of the esym list.
* gfortran.h : Add the vindex field to the esym_list structure.
and eliminate the class_object field.
* resolve.c (check_class_members): Remove the setting of the
class_object field.
(vindex_expr): New function.
(get_class_from_expr): New function.
(resolve_class_compcall): Call the above to find the ultimate
class or derived component. If derived, do not generate the
esym list. Add and expression for the vindex to the esym list
by calling the above.
(resolve_class_typebound_call): The same.
2009-10-16 Paul Thomas <pault@gcc.gnu.org>
PR fortran/41648
* gfortran.dg/dynamic_dispatch_4.f03 : New test.
PR fortran/41656
* gfortran.dg/dynamic_dispatch_5.f03 : New test.
Jakub Jelinek [Thu, 15 Oct 2009 16:40:52 +0000 (18:40 +0200)]
dwarf2out.c (dwarf_tag_name): Handle DW_TAG_rvalue_reference_type and DW_TAG_template_alias.
* dwarf2out.c (dwarf_tag_name): Handle DW_TAG_rvalue_reference_type
and DW_TAG_template_alias.
(dwarf_attr_name): Handle DW_AT_main_subprogram,
DW_AT_data_bit_offset, DW_AT_const_expr, DW_AT_enum_class,
DW_AT_linkage_name, DW_AT_GNU_guarded_by, DW_AT_GNU_pt_guarded_by,
DW_AT_GNU_guarded, DW_AT_GNU_pt_guarded, DW_AT_GNU_locks_excluded,
DW_AT_GNU_exclusive_locks_required, DW_AT_GNU_shared_locks_required
and DW_AT_GNU_odr_signature.
(dwarf_form_name): Handle DW_FORM_sec_offset, DW_FORM_exprloc,
DW_FORM_flag_present and DW_FORM_ref_sig8.
(output_signature): Only print name on the first byte.
(output_die): Likewise for dw_val_class_data8.
* include/dwarf2.h (DW_LANG_Python): Add comment that it is
a DWARF 4 addition.
Richard Guenther [Thu, 15 Oct 2009 16:04:29 +0000 (16:04 +0000)]
re PR lto/41668 (ICE in get_alias_set, at alias.c:698)
2009-10-15 Richard Guenther <rguenther@suse.de>
PR lto/41668
* gimple.c (compare_type_names_p): Handle anonymous names
differently based on new mode argument.
(gimple_types_compatible_p): For structs also compare the tags.
(iterative_hash_type_name): Rename to ...
(iterative_hash_name): ... this. Hash all names.
(iterative_hash_gimple_type): Fix hashing the struct tag of
pointer targets. Hash field decl names.
2009-10-15 Rafael Avila de Espindola <espindola@google.com>
* lto-plugin.c (resolution_file): New.
(free_1): Update comment.
(free_2): Free resolution_file.
(write_resolution): Write resolution to specified file. Use the
syms array from the symbol table.
(all_symbols_read_handler): Delay call to free_1 past call to
write_resolution.
(process_option): Add a -resolution option.
Jim Blandy [Thu, 15 Oct 2009 08:56:02 +0000 (08:56 +0000)]
2009-10-15 Jim Blandy <jimb@red-bean.com>
* libgnuintl.h (_INTL_MAY_RETURN_STRING_ARG, gettext, dgettext)
(dcgettext, ngettext, dngettext, dcngettext): Backport changes
from current gettext to provide GCC format_arg attributes.
Paolo Carlini [Thu, 15 Oct 2009 01:16:53 +0000 (01:16 +0000)]
basic_string.h (operator+=(initializer_list<>), [...]): Forward to the append overload taking a const CharT* pointer and a size...
2009-10-14 Paolo Carlini <paolo.carlini@oracle.com>
* include/bits/basic_string.h (operator+=(initializer_list<>),
append(initializer_list<>)): Forward to the append overload taking
a const CharT* pointer and a size, thus avoiding instantiating
unnecessarily in the built library the overload taking a pair of
iterators.
(operator=(initializer_list<>), assign(initializer_list<>)): Likewise
for assign.
(insert(iterator, initializer_list<>): Likewise for insert.
Paolo Carlini [Thu, 15 Oct 2009 00:01:05 +0000 (00:01 +0000)]
c++config: Do not disable extern templates for string in plain parallel-mode and in...
2009-10-14 Paolo Carlini <paolo.carlini@oracle.com>
* include/bits/c++config: Do not disable extern templates for string
in plain parallel-mode and in profile-mode; add comment explaining
_GLIBCXX_EXTERN_TEMPLATE == -1.
* testsuite/ext/profile/mutex_extensions.cc: Adjust dg-error line.