On 12/02/13 16:02, Jakub Jelinek wrote:
Hi!
tree-nested.c uses declare_vars with last argument true, which
relies on BLOCK_VARS of gimple_bind_block being a tail
of the gimple_bind_vars chain. But unfortunately a debug info
improvement I've added to gimplify_var_or_parm_decl 4 years ago
violates this assumption, in that it adds some VAR_DECLs
at the head of BLOCK_VARS (DECL_INITIAL (current_function_decl))
chain, but doesn't adjust gimple_bind_vars chain correspondingly.
Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux,
ok for trunk/4.8?
2013-12-02 Jakub Jelinek <ja...@redhat.com>
PR middle-end/59011
* gimplify.c (nonlocal_vla_vars): New variable.
(gimplify_var_or_parm_decl): Put VAR_DECLs for VLAs into
nonlocal_vla_vars chain.
(gimplify_body): Call declare_vars on nonlocal_vla_vars chain
if outer_bind has DECL_INITIAL (current_function_decl) block.
* gcc.dg/pr59011.c: New test.
OK for the trunk. Branch maintainers have final call on their
respective branches.
jeff