On 10/23/2017 11:18 AM, Richard Sandiford wrote: > This patch makes a few small poly_int64 changes to reload1.c, > mostly related to eliminations. Again, there's no real expectation > that reload will be used for targets that have polynomial-sized modes, > but it seemed easier to convert it anyway. And since all the routines are "free", there's nothing that really prevents them from being called from elsewhere. So better to go ahead and convert 'em.
If someone were to look at a refactoring project, pulling all the static objects into a class and using that to drive turning the free functions into methods would help give us better isolation of this code. One could argue we should do this across the board to cut down on the amount of globals we continue to access and make it clearer what routines need those globals vs which are truly free standing functions. > > > 2017-10-23 Richard Sandiford <richard.sandif...@linaro.org> > Alan Hayward <alan.hayw...@arm.com> > David Sherwood <david.sherw...@arm.com> > > gcc/ > * reload1.c (elim_table): Change initial_offset, offset and > previous_offset from HOST_WIDE_INT to poly_int64_pod. > (offsets_at): Change the target array's element type from > HOST_WIDE_INT to poly_int64_pod. > (set_label_offsets, eliminate_regs_1, eliminate_regs_in_insn) > (elimination_costs_in_insn, update_eliminable_offsets) > (verify_initial_elim_offsets, set_offsets_for_label) > (init_eliminable_invariants): Update after above changes. OK. jeff