diff options
author | Richard Kenner <kenner@vlsi1.ultra.nyu.edu> | 2004-04-12 21:25:55 +0000 |
---|---|---|
committer | Richard Kenner <kenner@gcc.gnu.org> | 2004-04-12 17:25:55 -0400 |
commit | 1c9766da11d71cb57f8962a2eb88833c1ca966f5 (patch) | |
tree | fc6c6b14412060a9d6d90d3f45c768a4648b7f4b /gcc/stmt.c | |
parent | 040e098a5de9115501bd76ce0ea7adc9a0eded21 (diff) | |
download | gcc-1c9766da11d71cb57f8962a2eb88833c1ca966f5.zip gcc-1c9766da11d71cb57f8962a2eb88833c1ca966f5.tar.gz gcc-1c9766da11d71cb57f8962a2eb88833c1ca966f5.tar.bz2 |
c-decl.c (finish_decl): Make a decl_stmt for a variable-sized TYPE_DECL.
* c-decl.c (finish_decl): Make a decl_stmt for a variable-sized
TYPE_DECL.
* c-semantics.c (genrtl_decl_stmt): Handle TYPE_DECL.
* stmt.c (expand_decl): Remove redundant expansion of TYPE_DOMAIN.
* stor-layout.c (variable_size): Don't check for MINUS_EXPR.
Use skip_simple_arithmetic to find SAVE_EXPR.
(force_type_save_exprs, force_type_save_exprs_1): New functions.
* tree-inline.c (remap_type, case POINTER_TYPE, case REFERENCE_TYPE):
Properly chain multiple pointers.
(copy_tree_r): Copy a TYPE_DECL.
* tree.c (variably_modified_type_p): Add some missing tests and
make some other minor changes.
* tree.h (force_type_save_exprs): New declaration.
* gcc.c-torture/execute/20040411-1.c: New test.
From-SVN: r80629
Diffstat (limited to 'gcc/stmt.c')
-rw-r--r-- | gcc/stmt.c | 9 |
1 files changed, 2 insertions, 7 deletions
@@ -4013,13 +4013,8 @@ expand_decl (tree decl) do_pending_stack_adjust (); save_stack_pointer (); - /* In function-at-a-time mode, variable_size doesn't expand this, - so do it now. */ - if (TREE_CODE (type) == ARRAY_TYPE && TYPE_DOMAIN (type)) - expand_expr (TYPE_MAX_VALUE (TYPE_DOMAIN (type)), - const0_rtx, VOIDmode, 0); - - /* Compute the variable's size, in bytes. */ + /* Compute the variable's size, in bytes. This will expand any + needed SAVE_EXPRs for the first time. */ size = expand_expr (DECL_SIZE_UNIT (decl), NULL_RTX, VOIDmode, 0); free_temp_slots (); |