This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH 001/236] Convert lab_rtx_for_bb from pointer_map_t to pointer_map<rtx>
- From: David Malcolm <dmalcolm at redhat dot com>
- To: Trevor Saunders <tsaunders at mozilla dot com>
- Cc: Jeff Law <law at redhat dot com>, gcc-patches at gcc dot gnu dot org
- Date: Tue, 12 Aug 2014 20:45:35 -0400
- Subject: Re: [PATCH 001/236] Convert lab_rtx_for_bb from pointer_map_t to pointer_map<rtx>
- Authentication-results: sourceware.org; auth=none
- References: <1407345815-14551-1-git-send-email-dmalcolm at redhat dot com> <1407345815-14551-2-git-send-email-dmalcolm at redhat dot com> <53EA7E1F dot 1030906 at redhat dot com> <20140812211548 dot GA28581 at tsaunders-iceball dot corp dot tor1 dot mozilla dot com>
On Tue, 2014-08-12 at 17:15 -0400, Trevor Saunders wrote:
> On Tue, Aug 12, 2014 at 02:50:39PM -0600, Jeff Law wrote:
> > On 08/06/14 11:19, David Malcolm wrote:
> > >This gives a slight improvement in typesafety in cfgexpand.c
> > >
> > >gcc/
> > > * cfgexpand.c (lab_rtx_for_bb): Convert from pointer_map_t to
> > > pointer_map<rtx>.
> > > (label_rtx_for_bb): Update for conversion of lab_rtx_for_bb to
> > > a pointer_map<rtx>, eliminating casts from void* to rtx.
> > > (expand_gimple_basic_block): Likewise.
> > > (pass_expand::execute): Likewise, using new/delete of
> > > pointer_map<rtx> rathern than pointer_map_create/destroy. NULLify
> > > the lab_rtx_for_bb ptr after deletion for good measure.
> > OK. I think this is still appropriate. It might even still apply
> > cleanly.
> actually I suspect this patch is totally obsolete after my patches last
> week to remove pointer_map. This is now a hash_map<basic_block, rtx> *.
> sorry about the duplicated effort :/
I believe in an earlier version of this patchkit I then updated it from
pointer_map<rtx> to pointer_map<rtx_code_label *>.
In theory the fix would then be to convert it from
hash_map<basic_block, rtx> *
hash_map<basic_block, rtx_code_label *> *
But looking over the patches it looks like I dropped the later usage of
rtx_code_label * for some reason (perhaps when I ran into the issues
mentioned in patch 2).
Maybe something to look at once the rest of the patches are in, I guess.
> > Seems like this could have gone forward independently of everything else.
> > jeff