Richard Kenner <[EMAIL PROTECTED]> wrote: > /* Otherwise, if we are taking the address of something that is > neither a refence, declaration, or constant, make a variable for the operand > here and then take its address. If we don't do it this way, we may > confuse the gimplifier because it needs to know the variable is > addressable at this point. This duplicates code in > internal_get_tmp_var, which is unfortunate. */ > else if (TREE_CODE_CLASS (TREE_CODE (op)) != tcc_reference > && TREE_CODE_CLASS (TREE_CODE (op)) != tcc_declaration > && TREE_CODE_CLASS (TREE_CODE (op)) != tcc_constant) > { > tree new_var = create_tmp_var (TREE_TYPE (op), "A"); > tree mod = build (MODIFY_EXPR, TREE_TYPE (op), new_var, op); > > TREE_ADDRESSABLE (new_var) = 1; > if (TREE_CODE (TREE_TYPE (op)) == COMPLEX_TYPE) > DECL_COMPLEX_GIMPLE_REG_P (new_var) = 1; > > if (EXPR_HAS_LOCATION (op)) > SET_EXPR_LOCUS (mod, EXPR_LOCUS (op)); > > gimplify_and_add (mod, pre_p); > TREE_OPERAND (expr, 0) = new_var; > recompute_tree_invarant_for_addr_expr (expr); > return GS_ALL_DONE; > }
Can't you use get_initialized_tmp_var, then? -- Giovanni Bajo