This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH 2/2 v3][IRA,LRA] Fix PR86939, IRA incorrectly creates an interference between a pseudo register and a hard register
- From: Peter Bergner <bergner at linux dot ibm dot com>
- To: Renlin Li <renlin dot li at foss dot arm dot com>
- Cc: Ramana Radhakrishnan <ramana dot gcc at googlemail dot com>, Jeff Law <law at redhat dot com>, Vladimir Makarov <vmakarov at redhat dot com>, Christophe Lyon <christophe dot lyon at linaro dot org>, gcc-patches <gcc-patches at gcc dot gnu dot org>, Segher Boessenkool <segher at kernel dot crashing dot org>, Ramana Radhakrishnan <Ramana dot Radhakrishnan at arm dot com>, Kyrylo Tkachov <kyrylo dot tkachov at arm dot com>
- Date: Tue, 6 Nov 2018 12:46:25 -0600
- Subject: Re: [PATCH 2/2 v3][IRA,LRA] Fix PR86939, IRA incorrectly creates an interference between a pseudo register and a hard register
- References: <db00fba8-f392-510f-7f75-31dd1eed6f87@linux.ibm.com> <CAKdteOY-WBs5qiDXUz-9ECb0JDat9pEhnu+t9m_N6_pyxd68rA@mail.gmail.com> <191bf9ee-98c4-b87e-cc65-40e1fb5de0ea@linux.ibm.com> <CAKdteOZy3BBGy5LW1Lf+sdhsLZtK08VEGNvwnZtBXoON6YuNJQ@mail.gmail.com> <c232f957-f5e1-ea5c-f5bf-77622f01f0e9@redhat.com> <bb4202ae-efae-9bc6-9bd4-7129f64c5992@linux.ibm.com> <478a817c-719b-9c3c-5b38-de7b277d9f93@linux.ibm.com> <13a249ee-160b-2b28-151c-bed3faacbfc1@linux.ibm.com> <0363139a-01af-b0eb-0941-111c1d7395b5@redhat.com> <f2c1737a-6323-214b-91bf-140e5fc983f5@linux.ibm.com> <3cdd23c9-5d07-c26d-9a10-42a4a9d6f77a@foss.arm.com> <b7518a7d-bdd6-679f-c077-89f044444b90@linux.ibm.com> <90073537-824d-697c-0ed8-9b611f9064c5@redhat.com> <e1646057-b120-dfe2-5cc3-8eb4eb19f84a@linux.ibm.com> <db5cb080-6b34-88a4-7c81-4d938006f843@redhat.com> <57966a2f-6dfd-7f10-266e-2732d0df6874@foss.arm.com> <CAJA7tRa_ECu=LoFzEbKbHYOYv2YQ-iQxJpWXL0y1h-Q-Eqyeeg@mail.gmail.com> <a0bc0abf-3b83-5842-2d67-560da5ef1def@foss.arm.com>
On 11/6/18 6:23 AM, Renlin Li wrote:
> I just did a bootstrap again with everything up to r264897 which is Oct 6.
> it produce the ICE I mentioned on the PR87899.
>
> The first combiner patch on Oct 22.
Do the testsuite results (for disable-bootstrap builds) differ between
r264896 and r264897? If so, that would be much easier to track down.
If not, maybe the following patch could help to narrow down which gcc
source file(s) are being miscompiled by allowing you to disable the
special handling of copy conflicts with an option? The option default
(ie, not using the option or -fno-ira-copies-conflict) is the same behavior
as now and -fira-copies-conflict would make things behave like they did
before my patch.
Peter
Index: gcc/common.opt
===================================================================
--- gcc/common.opt (revision 265402)
+++ gcc/common.opt (working copy)
@@ -1761,6 +1761,10 @@ Enum(ira_region) String(all) Value(IRA_R
EnumValue
Enum(ira_region) String(mixed) Value(IRA_REGION_MIXED)
+fira-copies-conflict
+Common Report Var(flag_ira_copies_conflict) Init(0) Optimization
+Make pseudos connected by a copy conflict
+
fira-hoist-pressure
Common Report Var(flag_ira_hoist_pressure) Init(1) Optimization
Use IRA based register pressure calculation
Index: gcc/ira-lives.c
===================================================================
--- gcc/ira-lives.c (revision 265402)
+++ gcc/ira-lives.c (working copy)
@@ -1066,7 +1066,7 @@ non_conflicting_reg_copy_p (rtx_insn *in
{
/* Reload has issues with overlapping pseudos being assigned to the
same hard register, so don't allow it. See PR87600 for details. */
- if (!targetm.lra_p ())
+ if (flag_ira_copies_conflict || !targetm.lra_p ())
return NULL_RTX;
rtx set = single_set (insn);
- References:
- Re: [PATCH 2/2 v3][IRA,LRA] Fix PR86939, IRA incorrectly creates an interference between a pseudo register and a hard register
- Re: [PATCH 2/2 v3][IRA,LRA] Fix PR86939, IRA incorrectly creates an interference between a pseudo register and a hard register
- Re: [PATCH 2/2 v3][IRA,LRA] Fix PR86939, IRA incorrectly creates an interference between a pseudo register and a hard register
- Re: [PATCH 2/2 v3][IRA,LRA] Fix PR86939, IRA incorrectly creates an interference between a pseudo register and a hard register
- Re: [PATCH 2/2 v3][IRA,LRA] Fix PR86939, IRA incorrectly creates an interference between a pseudo register and a hard register
- Re: [PATCH 2/2 v3][IRA,LRA] Fix PR86939, IRA incorrectly creates an interference between a pseudo register and a hard register
- Re: [PATCH 2/2 v3][IRA,LRA] Fix PR86939, IRA incorrectly creates an interference between a pseudo register and a hard register
- From: Ramana Radhakrishnan
- Re: [PATCH 2/2 v3][IRA,LRA] Fix PR86939, IRA incorrectly creates an interference between a pseudo register and a hard register