svn commit: r260231 - in stable/9/contrib/gcc: . cp
Pedro F. Giffuni
pfg at FreeBSD.org
Fri Jan 3 15:55:22 UTC 2014
Author: pfg
Date: Fri Jan 3 15:55:20 2014
New Revision: 260231
URL: http://svnweb.freebsd.org/changeset/base/260231
Log:
MFC r259655 (partial), r259944
gcc: merge small upstream changes.
Fix for PR c++/29928
Backport from mainline:
2007-04-24 Hui-May Chang <hm.chang at apple.com>
* reload1.c (merge_assigned_reloads) : Do not merge a RELOAD_OTHER
instruction with a RELOAD_FOR_OPERAND_ADDRESS instruction.
Obtained from: gcc 4.3 (rev. r124115, 124724: GPLv2)
Modified:
stable/9/contrib/gcc/ChangeLog.gcc43
stable/9/contrib/gcc/cp/rtti.c
stable/9/contrib/gcc/reload1.c
Directory Properties:
stable/9/ (props changed)
stable/9/contrib/gcc/ (props changed)
Modified: stable/9/contrib/gcc/ChangeLog.gcc43
==============================================================================
--- stable/9/contrib/gcc/ChangeLog.gcc43 Fri Jan 3 15:54:12 2014 (r260230)
+++ stable/9/contrib/gcc/ChangeLog.gcc43 Fri Jan 3 15:55:20 2014 (r260231)
@@ -139,6 +139,11 @@
alignment for amdfam10 architecture. Increasing the max loop
alignment to 24 bytes.
+2007-04-24 Hui-May Chang <hm.chang at apple.com> (r124115)
+
+ * reload1.c (merge_assigned_reloads) : Do not merge a RELOAD_OTHER
+ instruction with a RELOAD_FOR_OPERAND_ADDRESS instruction.
+
2007-04-16 Lawrence Crowl <crowl at google.com> (r123909)
* doc/invoke.texi (Debugging Options): Add documentation for the
Modified: stable/9/contrib/gcc/cp/rtti.c
==============================================================================
--- stable/9/contrib/gcc/cp/rtti.c Fri Jan 3 15:54:12 2014 (r260230)
+++ stable/9/contrib/gcc/cp/rtti.c Fri Jan 3 15:55:20 2014 (r260231)
@@ -238,7 +238,7 @@ get_tinfo_decl_dynamic (tree exp)
/* Peel off cv qualifiers. */
type = TYPE_MAIN_VARIANT (type);
- if (!VOID_TYPE_P (type))
+ if (CLASS_TYPE_P (type))
type = complete_type_or_else (type, exp);
if (!type)
@@ -430,7 +430,7 @@ get_typeid (tree type)
that is the operand of typeid are always ignored. */
type = TYPE_MAIN_VARIANT (type);
- if (!VOID_TYPE_P (type))
+ if (CLASS_TYPE_P (type))
type = complete_type_or_else (type, NULL_TREE);
if (!type)
Modified: stable/9/contrib/gcc/reload1.c
==============================================================================
--- stable/9/contrib/gcc/reload1.c Fri Jan 3 15:54:12 2014 (r260230)
+++ stable/9/contrib/gcc/reload1.c Fri Jan 3 15:55:20 2014 (r260231)
@@ -6236,15 +6236,23 @@ merge_assigned_reloads (rtx insn)
transfer_replacements (i, j);
}
- /* If this is now RELOAD_OTHER, look for any reloads that load
- parts of this operand and set them to RELOAD_FOR_OTHER_ADDRESS
- if they were for inputs, RELOAD_OTHER for outputs. Note that
- this test is equivalent to looking for reloads for this operand
- number. */
- /* We must take special care with RELOAD_FOR_OUTPUT_ADDRESS; it may
- share registers with a RELOAD_FOR_INPUT, so we can not change it
- to RELOAD_FOR_OTHER_ADDRESS. We should never need to, since we
- do not modify RELOAD_FOR_OUTPUT. */
+ /* If this is now RELOAD_OTHER, look for any reloads that
+ load parts of this operand and set them to
+ RELOAD_FOR_OTHER_ADDRESS if they were for inputs,
+ RELOAD_OTHER for outputs. Note that this test is
+ equivalent to looking for reloads for this operand
+ number.
+
+ We must take special care with RELOAD_FOR_OUTPUT_ADDRESS;
+ it may share registers with a RELOAD_FOR_INPUT, so we can
+ not change it to RELOAD_FOR_OTHER_ADDRESS. We should
+ never need to, since we do not modify RELOAD_FOR_OUTPUT.
+
+ It is possible that the RELOAD_FOR_OPERAND_ADDRESS
+ instruction is assigned the same register as the earlier
+ RELOAD_FOR_OTHER_ADDRESS instruction. Merging these two
+ instructions will cause the RELOAD_FOR_OTHER_ADDRESS
+ instruction to be deleted later on. */
if (rld[i].when_needed == RELOAD_OTHER)
for (j = 0; j < n_reloads; j++)
@@ -6252,6 +6260,7 @@ merge_assigned_reloads (rtx insn)
&& rld[j].when_needed != RELOAD_OTHER
&& rld[j].when_needed != RELOAD_FOR_OTHER_ADDRESS
&& rld[j].when_needed != RELOAD_FOR_OUTPUT_ADDRESS
+ && rld[j].when_needed != RELOAD_FOR_OPERAND_ADDRESS
&& (! conflicting_input
|| rld[j].when_needed == RELOAD_FOR_INPUT_ADDRESS
|| rld[j].when_needed == RELOAD_FOR_INPADDR_ADDRESS)
More information about the svn-src-stable-9
mailing list