2012-01-28 Sandra Loosemore <sandra@codesourcery.com>
gcc/
* doc/invoke.texi: Correct hyphenation of "floating point",
"double precision", and related terminology throughout the file.
From-SVN: r183663
2012-01-27 Paolo Carlini <paolo.carlini@oracle.com>
PR libstdc++/51795
* include/bits/random.h (linear_congruential_generator): Add
static_assert preventing instantiation for values of 'a' and 'm'
currently handled incorrectly but _Mod::__calc.
* include/bits/random.tcc (seed_seq::generate): Avoid unsafe
uses of _Mod::__calc.
From-SVN: r183655
2011-01-27 Rafael Avila de Espindola <rafael.espindola@gmail.com>
* libsupc++/typeinfo: Correctly match #pragma GCC visibility
pop with #pragma GCC visibility push.
From-SVN: r183641
PR c++/51852
* pt.c (tsubst_pack_expansion): Delete and restore
local_specialization whenever need_local_specialization, not just
when saved_local_specializations is non-NULL.
* g++.dg/other/gc5.C: New test.
From-SVN: r183637
2012-01-27 Richard Guenther <rguenther@suse.de>
PR tree-optimization/52020
* tree-sra.c (sra_modify_assign): Do not transform clobbers.
From-SVN: r183633
2012-01-27 Richard Guenther <rguenther@suse.de>
PR tree-optimization/50444
* tree-sra.c (build_ref_for_offset): Properly adjust the
MEM_REF type for unaligned accesses.
* gcc.dg/torture/pr50444.c: New testcase.
From-SVN: r183630
2012-01-27 Richard Guenther <rguenther@suse.de>
PR tree-optimization/50444
* expr.c (mem_ref_refers_to_non_mem_p): New function.
(expand_assignment): Use it. Properly handle misaligned
bases when expanding stores to component references.
(expand_expr_real_1): Use mem_ref_refers_to_non_mem_p and
refactor that case.
From-SVN: r183629
PR middle-end/51389
* Makefile.in (tree-data-ref.o): Depend on $(PARAMS_H).
* tree-data-ref.h (find_data_references_in_loop): Remove declaration.
* tree-data-ref.c (find_data_references_in_loop): Make static.
(compute_all_dependences): Change return type to bool. Bail out
for too many datarefs in a loop. Move the hunk resetting the data
dependences vector from ...
(compute_data_dependences_for_loop): ... here. Account for
compute_all_dependences returning false.
(compute_data_dependences_for_bb): Likewise.
* params.def (PARAM_LOOP_MAX_DATAREFS_FOR_DATADEPS): New param.
* doc/invoke.texi (loop-max-datarefs-for-datadeps): Document it.
From-SVN: r183624
2012-01-27 Richard Guenther <rguenther@suse.de>
PR middle-end/51959
* expr.c (store_field): Use the alias-set of the scratch memory
for storing to it.
* g++.dg/torture/pr51959.C: New testcase.
From-SVN: r183616
2012-01-27 Paul Thomas <pault@gcc.gnu.org>
Tobias Burnus <burnus@gcc.gnu.org>
PR fortran/48705
PR fortran/51870
PR fortran/51943
PR fortran/51946
* trans-array.c (gfc_array_init_size): Add two extra arguments
to convey the dynamic element size of a calls object and to
return the number of elements that have been allocated.
(gfc_array_allocate): Add the same arguments and use them to
call gfc_array_init_size. Before the allocation dereference
the data pointer, if necessary. Set the allocated array to zero
if the class element size or expr3 are non-null.
* trans-expr.c (gfc_conv_class_to_class): Give this function
global scope.
(get_class_array_ref): New function.
(gfc_copy_class_to_class): New function.
* trans-array.h : Update prototype for gfc_array_allocate.
* trans-stmt.c (gfc_trans_allocate): For non-variable class
STATUS expressions extract the class object and the dynamic
element size. Use the latter to call gfc_array_allocate and
the former for setting the vptr and, via
gfc_copy_class_to_clasfc_cs, to copy to the allocated data.
* trans.h : Prototypes for gfc_get_class_array_ref,
gfc_copy_class_to_class and gfc_conv_class_to_class.
2012-01-27 Paul Thomas <pault@gcc.gnu.org>
Tobias Burnus <burnus@gcc.gnu.org>
PR fortran/48705
* gfortran.dg/class_allocate_11.f03: New.
PR fortran/51870
PR fortran/51943
PR fortran/51946
* gfortran.dg/class_allocate_7.f03: New.
* gfortran.dg/class_allocate_8.f03: New.
* gfortran.dg/class_allocate_9.f03: New.
* gfortran.dg/class_allocate_10.f03: New.
Co-Authored-By: Tobias Burnus <burnus@gcc.gnu.org>
From-SVN: r183613
* gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Do not set
an alignment on fields of the RETURN type built for the CICO mechanism.
From-SVN: r183611
* gcc-interface/trans.c (gnat_to_gnu): Avoid making a SAVE_EXPR for
a call to a function that returns an unconstrained type with default
discriminant. Similarly, avoid doing the conversion to the nominal
From-SVN: r183610
* gcc-interface/ada-tree.h (DECL_ALIASED_P): New flag.
* gcc-interface/decl.c (is_variable_size): Rename to...
(type_has_variable_size): ...this.
(adjust_packed): Adjust to above renaming.
(gnat_to_gnu_field): Set DECL_ALIASED_P on the field.
(field_is_artificial): New predicate.
(field_is_aliased): Likewise.
(field_has_self_size): Likewise.
(field_has_variable_size): Likewise.
(components_to_record): Record information for the final layout during
the first pass on fields.
If there is an aliased field placed after a field whose length depends
on discriminants, put all the fields of the latter sort, last.
From-SVN: r183609
* gcc-interface/gigi.h (get_minimal_subprog_decl): Declare.
* gcc-interface/decl.c (get_minimal_subprog_decl): New function.
* gcc-interface/trans.c (Attribute_to_gnu): Use it for the prefix of an
Access-like attribute in a dispatch table if the subprogram is public.
From-SVN: r183607
* gcc-interface/decl.c (gnat_to_gnu_entity) <object>: For an aliased
object with an unconstrained nominal subtype and if optimization isn't
enabled, create a special VAR_DECL for debugging purposes.
From-SVN: r183605