Comments

Hi,
this removes the XXXs I added with my prev/next shuffling. A reason for
some conditionals in iterator setups is that ENTRY/EXIT bbs don't have
il.gimple setup, while all other blocks have it always initialized (well,
as long as !BB_RTL of course). That annoyed me, but instead of simply
also allocating il.gimple for ENTRY/EXIT I folded gimple_bb_info directly
into basic_block_def. The latter is only two pointers, so wasting a
pointer just to point to them seems useless especially considering that we
hold very many BBs in !BB_RTL state (all of them, except for the very few
just being converted into RTL, one function at a time).
So, RTL BBs will be one word larger than before, while gimple BBs will be
overall one word smaller, save an indirection and save several condionals
in our low-level accessors.
This patch also folds in the trivial removal of const_gimple_seq that
Richi asked me for.
Regstrapped on x86_64-linux, all langs, no regressions. Okay for trunk?
Ciao,
Michael.
----------------
2012-05-02 Michael Matz <matz@suse.de>
* basic-block.h (struct rtl_bb_info, struct gimple_bb_info): Move
in front of basic_block_def.
(struct basic_block_def): Make il.gimple the full struct, not a
pointer.
(__assert_gimple_bb_smaller_rtl_bb): Asserting typedef.
* cfgexpand.c (expand_gimple_basic_block): Clear all il.gimple
members.
* gimple-iterator.c (gimple_stmt_iterator): Don't special case
NULL il.gimple, which can't happen anymore.
* gimple.h (bb_seq): il.gimple can't be NULL.
(bb_seq_add): Ditto.
(set_bb_seq): Adjust.
(gsi_start_bb, gsi_last_bb): Tidy.
* lto-streamer-in.c (make_new_block): Don't zero members that
are zeroed already, don't allocate a gimple_bb_info.
* tree-cfg.c (create_bb): Don't allocate a gimple_bb_info.
(remove_bb): Clear all il.gimple members.
(gimple_verify_flow_info): Adjust for flat il.gimple.
* tree-flow-inline.h (phi_nodes, phi_nodes_ptr, set_phi_nodes): Adjust.
* coretypes.h (const_gimple_seq): Remove typedef.
* gimple.h (gimple_seq_first): Take gimple_seq.
(gimple_seq_first_stmt): Ditto.
(gimple_seq_last): Ditto.
(gimple_seq_last_stmt): Ditto.
(gimple_seq_empty_p): Ditto.