Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] gcc: ARC Fix conditional move contstraint.
@ 2016-08-26  9:28 Vlad Zakharov
  2016-08-26 13:37 ` Thomas Petazzoni
  2016-08-26 20:53 ` Thomas Petazzoni
  0 siblings, 2 replies; 4+ messages in thread
From: Vlad Zakharov @ 2016-08-26  9:28 UTC (permalink / raw)
  To: buildroot

The patch solves one of the ARC internal compiler issues.

Fixes:
http://autobuild.buildroot.net/results/1c4/1c4493c6a18b7a93a0368420c8f79032f9330891//
http://autobuild.buildroot.net/results/510/51071b790866b0c7083de3a94ad2a427009096af//
http://autobuild.buildroot.net/results/09e/09e037c628ca2a27d8eb832dd070f50ec7ebb72a//
Signed-off-by: Vlad Zakharov <vzakhar@synopsys.com>
---
 .../950-ARC-Fix-conditional-move-contstraint.patch | 34 ++++++++++++++++++++++
 1 file changed, 34 insertions(+)
 create mode 100644 package/gcc/arc-2016.09-eng008/950-ARC-Fix-conditional-move-contstraint.patch

diff --git a/package/gcc/arc-2016.09-eng008/950-ARC-Fix-conditional-move-contstraint.patch b/package/gcc/arc-2016.09-eng008/950-ARC-Fix-conditional-move-contstraint.patch
new file mode 100644
index 0000000..153af6d
--- /dev/null
+++ b/package/gcc/arc-2016.09-eng008/950-ARC-Fix-conditional-move-contstraint.patch
@@ -0,0 +1,34 @@
+From e569e9c2ce2273f5175e0928efd6e45c3e71c45f Mon Sep 17 00:00:00 2001
+From: Claudiu Zissulescu <claziss@synopsys.com>
+Date: Mon, 22 Aug 2016 19:58:25 +0200
+Subject: [PATCH] [ARC] Fix conditional move contstraint
+
+Move pattern (movsi_insn) allows predicated instructions to be
+instructions which can hold all registers.  However, the conditional
+variant doesn't.  This patch fixes this problem.
+
+2016-08-22  Claudiu Zissulescu  <claziss@synopsys.com>
+
+	* config/arc/arc.md (movsi_cond_exec): Update constraint.
+
+Signed-off-by: Claudiu Zissulescu  <claziss@synopsys.com>
+---
+ gcc/config/arc/arc.md | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/gcc/config/arc/arc.md b/gcc/config/arc/arc.md
+index d87174a..607c6e6 100644
+--- a/gcc/config/arc/arc.md
++++ b/gcc/config/arc/arc.md
+@@ -3603,7 +3603,7 @@
+      (match_operator 3 "proper_comparison_operator"
+        [(match_operand 2 "cc_register" "Rcc,Rcc") (const_int 0)])
+      (set (match_operand:SI 0 "dest_reg_operand" "=w,w")
+-	  (match_operand:SI 1 "nonmemory_operand" "Lc,?Cal")))]
++	  (match_operand:SI 1 "nonmemory_operand" "LRac,?Cal")))]
+   ""
+   "mov.%d3 %0,%S1"
+   [(set_attr "type" "cmove")
+-- 
+2.6.3
+
-- 
2.6.3

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [Buildroot] [PATCH] gcc: ARC Fix conditional move contstraint.
  2016-08-26  9:28 [Buildroot] [PATCH] gcc: ARC Fix conditional move contstraint Vlad Zakharov
@ 2016-08-26 13:37 ` Thomas Petazzoni
  2016-08-26 20:53 ` Thomas Petazzoni
  1 sibling, 0 replies; 4+ messages in thread
From: Thomas Petazzoni @ 2016-08-26 13:37 UTC (permalink / raw)
  To: buildroot

Hello,

Typo in the commit title: contstraint -> constraint

On Fri, 26 Aug 2016 12:28:32 +0300, Vlad Zakharov wrote:
> The patch solves one of the ARC internal compiler issues.
> 
> Fixes:
> http://autobuild.buildroot.net/results/1c4/1c4493c6a18b7a93a0368420c8f79032f9330891//
> http://autobuild.buildroot.net/results/510/51071b790866b0c7083de3a94ad2a427009096af//
> http://autobuild.buildroot.net/results/09e/09e037c628ca2a27d8eb832dd070f50ec7ebb72a//

Trailing slash not really needed, and we also need an empty line
between the commit log contents and the SoB line.

> Signed-off-by: Vlad Zakharov <vzakhar@synopsys.com>

I've fixed up those issues and applied to master!

> +diff --git a/gcc/config/arc/arc.md b/gcc/config/arc/arc.md
> +index d87174a..607c6e6 100644
> +--- a/gcc/config/arc/arc.md
> ++++ b/gcc/config/arc/arc.md
> +@@ -3603,7 +3603,7 @@
> +      (match_operator 3 "proper_comparison_operator"
> +        [(match_operand 2 "cc_register" "Rcc,Rcc") (const_int 0)])
> +      (set (match_operand:SI 0 "dest_reg_operand" "=w,w")
> +-	  (match_operand:SI 1 "nonmemory_operand" "Lc,?Cal")))]
> ++	  (match_operand:SI 1 "nonmemory_operand" "LRac,?Cal")))]

I have to say the gcc .md files are pretty arcane stuff, especially
when you see such patches :-)

Thanks for fixing this issue. I'll rebuild the ARC toolchain right
away, and deploy it on the autobuilders.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Buildroot] [PATCH] gcc: ARC Fix conditional move contstraint.
  2016-08-26  9:28 [Buildroot] [PATCH] gcc: ARC Fix conditional move contstraint Vlad Zakharov
  2016-08-26 13:37 ` Thomas Petazzoni
@ 2016-08-26 20:53 ` Thomas Petazzoni
  2016-08-30 17:44   ` Vlad Zakharov
  1 sibling, 1 reply; 4+ messages in thread
From: Thomas Petazzoni @ 2016-08-26 20:53 UTC (permalink / raw)
  To: buildroot

Vlad, Alexey, Eugeniy,

On Fri, 26 Aug 2016 12:28:32 +0300, Vlad Zakharov wrote:
> The patch solves one of the ARC internal compiler issues.
> 
> Fixes:
> http://autobuild.buildroot.net/results/1c4/1c4493c6a18b7a93a0368420c8f79032f9330891//
> http://autobuild.buildroot.net/results/510/51071b790866b0c7083de3a94ad2a427009096af//
> http://autobuild.buildroot.net/results/09e/09e037c628ca2a27d8eb832dd070f50ec7ebb72a//

FWIW, this last build issue is *not* fixed by this patch. This last
build failure is on mesa3d, with:

main/get.c: In function '_mesa_GetBooleani_v':
main/get.c:2320:1: error: insn does not satisfy its constraints:
 }
 ^
(insn 79 72 80 7 (set (reg/f:SI 147 virtual-stack-vars)
        (reg:SI 2 r2)) main/get.c:2315 3 {*movsi_insn}
     (nil))
main/get.c:2320:1: internal compiler error: in extract_constrain_insn, at recog.c:2190
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://bugs.buildroot.net/> for instructions.

And the build result
http://autobuild.buildroot.net/results/5cc/5ccb47e2af780982d71d924ef30008f16573ad73//build-end.log
is the *exact* same failure, but at commit
https://git.buildroot.net/buildroot/commit/?id=2567f6f2f34a1ecfc25604bf8bf93b8bc065fc63,
which is *after* I committed and pushed your ARC fix (and the
configuration was using the internal toolchain backend, so the
toolchain was built from scratch).

Best regards,

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Buildroot] [PATCH] gcc: ARC Fix conditional move contstraint.
  2016-08-26 20:53 ` Thomas Petazzoni
@ 2016-08-30 17:44   ` Vlad Zakharov
  0 siblings, 0 replies; 4+ messages in thread
From: Vlad Zakharov @ 2016-08-30 17:44 UTC (permalink / raw)
  To: buildroot

Hi Thomas,

Looks like I tried to build it in a slightly different conditions.?
I reproduced that bug and hope our team will be able to fix the issue soon.

Thank you for your remarks.

-- 
Best regards,
Vlad Zakharov <vzakhar@synopsys.com>

On Fri, 2016-08-26 at 22:53 +0200, Thomas Petazzoni wrote:
> Vlad, Alexey, Eugeniy,
> 
> On Fri, 26 Aug 2016 12:28:32 +0300, Vlad Zakharov wrote:
> > 
> > The patch solves one of the ARC internal compiler issues.
> > 
> > Fixes:
> > http://autobuild.buildroot.net/results/1c4/1c4493c6a18b7a93a0368420c8f79032f9330891//
> > http://autobuild.buildroot.net/results/510/51071b790866b0c7083de3a94ad2a427009096af//
> > http://autobuild.buildroot.net/results/09e/09e037c628ca2a27d8eb832dd070f50ec7ebb72a//
> FWIW, this last build issue is *not* fixed by this patch. This last
> build failure is on mesa3d, with:
> 
> main/get.c: In function '_mesa_GetBooleani_v':
> main/get.c:2320:1: error: insn does not satisfy its constraints:
> ?}
> ?^
> (insn 79 72 80 7 (set (reg/f:SI 147 virtual-stack-vars)
> ????????(reg:SI 2 r2)) main/get.c:2315 3 {*movsi_insn}
> ?????(nil))
> main/get.c:2320:1: internal compiler error: in extract_constrain_insn, at recog.c:2190
> Please submit a full bug report,
> with preprocessed source if appropriate.
> See <http://bugs.buildroot.net/> for instructions.
> 
> And the build result
> http://autobuild.buildroot.net/results/5cc/5ccb47e2af780982d71d924ef30008f16573ad73//build-end.log
> is the *exact* same failure, but at commit
> https://git.buildroot.net/buildroot/commit/?id=2567f6f2f34a1ecfc25604bf8bf93b8bc065fc63,
> which is *after* I committed and pushed your ARC fix (and the
> configuration was using the internal toolchain backend, so the
> toolchain was built from scratch).
> 
> Best regards,
> 
> Thomas

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2016-08-30 17:44 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-08-26  9:28 [Buildroot] [PATCH] gcc: ARC Fix conditional move contstraint Vlad Zakharov
2016-08-26 13:37 ` Thomas Petazzoni
2016-08-26 20:53 ` Thomas Petazzoni
2016-08-30 17:44   ` Vlad Zakharov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox