For a TYPENAME_TYPE, this is TYPENAME_TYPE_FULLNAME.
For a TEMPLATE_TEMPLATE_PARM or BOUND_TEMPLATE_TEMPLATE_PARM,
this is TEMPLATE_TEMPLATE_PARM_TEMPLATE_INFO.
+ For a FUNCTION_TYPE or METHOD_TYPE, this is TYPE_RAISES_EXCEPTIONS
BINFO_VIRTUALS
For a binfo, this is a TREE_LIST. The BV_DELTA of each node
After the class is defined, these fields hold other information. */
/* List of friends which were defined inline in this class definition. */
-#define CLASSTYPE_INLINE_FRIENDS(NODE) (TYPE_NONCOPIED_PARTS (NODE))
+#define CLASSTYPE_INLINE_FRIENDS(NODE) (CLASSTYPE_PURE_VIRTUALS (NODE))
/* Nonzero for _CLASSTYPE means that operator delete is defined. */
#define TYPE_GETS_DELETE(NODE) (TYPE_LANG_SPECIFIC(NODE)->gets_delete)
this type can raise. Each TREE_VALUE is a _TYPE. The TREE_VALUE
will be NULL_TREE to indicate a throw specification of `()', or
no exceptions allowed. */
-#define TYPE_RAISES_EXCEPTIONS(NODE) TYPE_NONCOPIED_PARTS (NODE)
+#define TYPE_RAISES_EXCEPTIONS(NODE) TYPE_BINFO (NODE)
/* For FUNCTION_TYPE or METHOD_TYPE, return 1 iff it is declared `throw()'. */
#define TYPE_NOTHROW_P(NODE) \
unsigned int, HOST_WIDE_INT, int));
static enum memory_use_mode
get_memory_usage_from_modifier PARAMS ((enum expand_modifier));
-static tree save_noncopied_parts PARAMS ((tree, tree));
-static tree init_noncopied_parts PARAMS ((tree, tree));
-static int fixed_type_p PARAMS ((tree));
static rtx var_rtx PARAMS ((tree));
static rtx expand_expr_unaligned PARAMS ((tree, unsigned int *));
static rtx expand_increment PARAMS ((tree, int, int));
return value;
}
\f
-/* Subroutine of expand_expr:
- save the non-copied parts (LIST) of an expr (LHS), and return a list
- which can restore these values to their previous values,
- should something modify their storage. */
-
-static tree
-save_noncopied_parts (lhs, list)
- tree lhs;
- tree list;
-{
- tree tail;
- tree parts = 0;
-
- for (tail = list; tail; tail = TREE_CHAIN (tail))
- if (TREE_CODE (TREE_VALUE (tail)) == TREE_LIST)
- parts = chainon (parts, save_noncopied_parts (lhs, TREE_VALUE (tail)));
- else
- {
- tree part = TREE_VALUE (tail);
- tree part_type = TREE_TYPE (part);
- tree to_be_saved = build (COMPONENT_REF, part_type, lhs, part);
- rtx target
- = assign_temp (build_qualified_type (part_type,
- (TYPE_QUALS (part_type)
- | TYPE_QUAL_CONST)),
- 0, 1, 1);
-
- parts = tree_cons (to_be_saved,
- build (RTL_EXPR, part_type, NULL_TREE,
- (tree) validize_mem (target)),
- parts);
- store_expr (TREE_PURPOSE (parts),
- RTL_EXPR_RTL (TREE_VALUE (parts)), 0);
- }
- return parts;
-}
-
-/* Subroutine of expand_expr:
- record the non-copied parts (LIST) of an expr (LHS), and return a list
- which specifies the initial values of these parts. */
-
-static tree
-init_noncopied_parts (lhs, list)
- tree lhs;
- tree list;
-{
- tree tail;
- tree parts = 0;
-
- for (tail = list; tail; tail = TREE_CHAIN (tail))
- if (TREE_CODE (TREE_VALUE (tail)) == TREE_LIST)
- parts = chainon (parts, init_noncopied_parts (lhs, TREE_VALUE (tail)));
- else if (TREE_PURPOSE (tail))
- {
- tree part = TREE_VALUE (tail);
- tree part_type = TREE_TYPE (part);
- tree to_be_initialized = build (COMPONENT_REF, part_type, lhs, part);
- parts = tree_cons (TREE_PURPOSE (tail), to_be_initialized, parts);
- }
- return parts;
-}
-
/* Subroutine of expand_expr: return nonzero iff there is no way that
EXP can reference X, which is being modified. TOP_P is nonzero if this
call is going to be used to determine whether we need a temporary
return 1;
}
-/* Subroutine of expand_expr: return nonzero iff EXP is an
- expression whose type is statically determinable. */
-
-static int
-fixed_type_p (exp)
- tree exp;
-{
- if (TREE_CODE (exp) == PARM_DECL
- || TREE_CODE (exp) == VAR_DECL
- || TREE_CODE (exp) == CALL_EXPR || TREE_CODE (exp) == TARGET_EXPR
- || TREE_CODE (exp) == COMPONENT_REF
- || TREE_CODE (exp) == ARRAY_REF)
- return 1;
- return 0;
-}
-
/* Subroutine of expand_expr: return rtx if EXP is a
variable or parameter; else return 0. */
{
tree lhs = TREE_OPERAND (exp, 0);
tree rhs = TREE_OPERAND (exp, 1);
- tree noncopied_parts = 0;
- tree lhs_type = TREE_TYPE (lhs);
temp = expand_assignment (lhs, rhs, ! ignore, original_target != 0);
- if (TYPE_NONCOPIED_PARTS (lhs_type) != 0 && !fixed_type_p (rhs))
- noncopied_parts
- = init_noncopied_parts (stabilize_reference (lhs),
- TYPE_NONCOPIED_PARTS (lhs_type));
-
- while (noncopied_parts != 0)
- {
- expand_assignment (TREE_VALUE (noncopied_parts),
- TREE_PURPOSE (noncopied_parts), 0, 0);
- noncopied_parts = TREE_CHAIN (noncopied_parts);
- }
return temp;
}
case MODIFY_EXPR:
{
/* If lhs is complex, expand calls in rhs before computing it.
- That's so we don't compute a pointer and save it over a call.
- If lhs is simple, compute it first so we can give it as a
- target if the rhs is just a call. This avoids an extra temp and copy
- and that prevents a partial-subsumption which makes bad code.
- Actually we could treat component_ref's of vars like vars. */
+ That's so we don't compute a pointer and save it over a
+ call. If lhs is simple, compute it first so we can give it
+ as a target if the rhs is just a call. This avoids an
+ extra temp and copy and that prevents a partial-subsumption
+ which makes bad code. Actually we could treat
+ component_ref's of vars like vars. */
tree lhs = TREE_OPERAND (exp, 0);
tree rhs = TREE_OPERAND (exp, 1);
- tree noncopied_parts = 0;
- tree lhs_type = TREE_TYPE (lhs);
temp = 0;
return const0_rtx;
}
- if (TYPE_NONCOPIED_PARTS (lhs_type) != 0
- && ! (fixed_type_p (lhs) && fixed_type_p (rhs)))
- noncopied_parts
- = save_noncopied_parts (stabilize_reference (lhs),
- TYPE_NONCOPIED_PARTS (lhs_type));
-
temp = expand_assignment (lhs, rhs, ! ignore, original_target != 0);
- while (noncopied_parts != 0)
- {
- expand_assignment (TREE_PURPOSE (noncopied_parts),
- TREE_VALUE (noncopied_parts), 0, 0);
- noncopied_parts = TREE_CHAIN (noncopied_parts);
- }
+
return temp;
}