Re: [patch] Use hard_reg_set_iterator in a few places

2012-10-15 Thread Richard Sandiford
Steven Bosscher writes: > * combine.c (record_dead_and_set_regs): Iterate over hard register set > with a hard_reg_set_iterator. > * cse.c (invalidate_for_call): Likewise. > * gcse.c (compute_hash_table_work): Likewise. > * loop-iv.c (simplify_using_initial_values): L

Re: [patch] Use hard_reg_set_iterator in a few places

2012-10-15 Thread Steven Bosscher
On Mon, Oct 15, 2012 at 6:42 PM, Steven Bosscher wrote: > Hello, > > GCC has hard_reg_set_iterator to iterate quickly over a HARD_REG_SET, > but it's not used a lot. Attached patch makes a few files use it to > iterate over regs_invalidated_by_call. If this is OK, I'd like to > convert loops over H

[patch] Use hard_reg_set_iterator in a few places

2012-10-15 Thread Steven Bosscher
Hello, GCC has hard_reg_set_iterator to iterate quickly over a HARD_REG_SET, but it's not used a lot. Attached patch makes a few files use it to iterate over regs_invalidated_by_call. If this is OK, I'd like to convert loops over HARD_REG_SETs to iterators where possible. Bootstrapped&tested on x