This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: RFC: LRA for x86/x86-64 [0/9]
- From: Steven Bosscher <stevenb dot gcc at gmail dot com>
- To: Vladimir Makarov <vmakarov at redhat dot com>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Thu, 4 Oct 2012 22:56:23 +0200
- Subject: Re: RFC: LRA for x86/x86-64 [0/9]
- References: <5064D9AD.5070504@redhat.com> <CABu31nPaws_d+QoBdO_PxSXjHsZ8Kb10aOM_9GeWQKhoyG6_mA@mail.gmail.com> <5065C066.4040600@redhat.com> <5066486B.70205@redhat.com> <CABu31nP-19ZPkW6twoWZbPqThsY6zhyvhiW445Co+Gr_CykL=A@mail.gmail.com> <CABu31nMthTq9vgtKkbcx_4h1Vtf_Kpa0CKA39A0Q=UjRq128ew@mail.gmail.com> <506A3FDE.8040709@redhat.com>
On Tue, Oct 2, 2012 at 3:14 AM, Vladimir Makarov <vmakarov@redhat.com> wrote:
> Analogous live ranges are used in IRA as intermidiate step to build a
> conflict graph.
Right, ira-lives.c and lra-lives.c look very much alike, the only
major difference is that the object of interest in an IRA live range
is an ira_object_t, and in an LRA live range it's just a regno. But
the code of create_start_finish_chains,
ira_rebuild_start_finish_chains,
remove_some_program_points_and_update_live_ranges, and most the live
range printing functions, are almost identical between lra-lives.c and
ira-lives.c. That looks like unnecessary code duplication. Do you
think some of that code be shared (esp. in a C++ world where maybe a
live range can be a container for another type)?
Ciao!
Steven