This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 1/3] make pattern_regs a vec

On Wed, Jul 27, 2016 at 04:15:02PM -0600, Jeff Law wrote:
> On 07/24/2016 03:10 PM, wrote:
> > From: Trevor Saunders <>
> > 
> > gcc/ChangeLog:
> > 
> > 2016-07-24  Trevor Saunders  <>
> > 
> > 	* store-motion.c (struct st_expr): Make pattern_regs a vector.
> > 	(extract_mentioned_regs): Append to a vector instead of
> > 	returning a rtx_expr_list.
> > 	(st_expr_entry): Adjust.
> > 	(store_ops_ok): Likewise.
> > 	(store_killed_in_insn): Likewise.
> > 	(find_moveable_store): Likewise.
> This is fine.  Though one has to wonder if a different representation than
> lists/vecs would work better given the walks.  A bitmap for example might
> work well since I think we just need to track register #s.

yeah, I just noticed there's actually a comment suggesting a regset
should be used.

I also noticed free_st_expr_entry needs to release the vec, I'll be
happy when we use auto_vec and stuff more and this sort of thing is
impossible.  I guess this used to work because the gc just cleaned up
after us being sloppy.  Anyway that seems pretty obvious so I'm tempted
to commit this as is in furtherance of killing rtl lists, and then we
can worry about making it a bitmap some other time.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]