All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] qt: fix build on powerpc_e500mc
@ 2018-08-29 17:36 Fabrice Fontaine
  2018-08-29 19:05 ` Thomas Petazzoni
  2018-09-01 21:30 ` Peter Korsgaard
  0 siblings, 2 replies; 4+ messages in thread
From: Fabrice Fontaine @ 2018-08-29 17:36 UTC (permalink / raw)
  To: buildroot

gcc bug internal compiler error: in validate_condition_mode, at
config/rs6000/rs6000.c:180744. Bug is fixed since gcc 7.2.
Workaround is to set -mno-isel, see
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60818 and
https://gcc.gnu.org/ml/gcc-patches/2016-02/msg01036.html

Fixes:
 - http://autobuild.buildroot.net/results/9b9d11b3281a72c8f54fc675408acb96d24d8e7e

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 package/qt/qt.mk | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/package/qt/qt.mk b/package/qt/qt.mk
index 1dcb05d6af..24ebbfdfdb 100644
--- a/package/qt/qt.mk
+++ b/package/qt/qt.mk
@@ -32,6 +32,15 @@ QT_LDFLAGS = $(TARGET_LDFLAGS)
 # use an older c++ standard to prevent build failure
 QT_CXXFLAGS += -std=gnu++98
 
+# gcc bug internal compiler error: in validate_condition_mode, at
+# config/rs6000/rs6000.c:180744. Bug is fixed since gcc 7.2.
+# Workaround is to set -mno-isel, see
+# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60818 and
+# https://gcc.gnu.org/ml/gcc-patches/2016-02/msg01036.html
+ifeq ($(BR2_powerpc_e500mc):$(BR2_TOOLCHAIN_GCC_AT_LEAST_8),y:)
+QT_CXXFLAGS += -mno-isel
+endif
+
 # Qt has some assembly function that are not present in thumb1 mode:
 # Error: selected processor does not support Thumb mode `swp r3,r7,[r4]'
 # so, we desactivate thumb mode
-- 
2.14.1

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

* [Buildroot] [PATCH 1/1] qt: fix build on powerpc_e500mc
  2018-08-29 17:36 [Buildroot] [PATCH 1/1] qt: fix build on powerpc_e500mc Fabrice Fontaine
@ 2018-08-29 19:05 ` Thomas Petazzoni
  2018-09-01 21:30 ` Peter Korsgaard
  1 sibling, 0 replies; 4+ messages in thread
From: Thomas Petazzoni @ 2018-08-29 19:05 UTC (permalink / raw)
  To: buildroot

Hello Fabrice,

Thanks for looking into these annoying remaining build failures, much
appreciated!

On Wed, 29 Aug 2018 19:36:54 +0200, Fabrice Fontaine wrote:
> gcc bug internal compiler error: in validate_condition_mode, at
> config/rs6000/rs6000.c:180744. Bug is fixed since gcc 7.2.
> Workaround is to set -mno-isel, see
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60818 and
> https://gcc.gnu.org/ml/gcc-patches/2016-02/msg01036.html
> 
> Fixes:
>  - http://autobuild.buildroot.net/results/9b9d11b3281a72c8f54fc675408acb96d24d8e7e
> 
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> ---
>  package/qt/qt.mk | 9 +++++++++
>  1 file changed, 9 insertions(+)
> 
> diff --git a/package/qt/qt.mk b/package/qt/qt.mk
> index 1dcb05d6af..24ebbfdfdb 100644
> --- a/package/qt/qt.mk
> +++ b/package/qt/qt.mk
> @@ -32,6 +32,15 @@ QT_LDFLAGS = $(TARGET_LDFLAGS)
>  # use an older c++ standard to prevent build failure
>  QT_CXXFLAGS += -std=gnu++98
>  
> +# gcc bug internal compiler error: in validate_condition_mode, at
> +# config/rs6000/rs6000.c:180744. Bug is fixed since gcc 7.2.
> +# Workaround is to set -mno-isel, see
> +# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60818 and
> +# https://gcc.gnu.org/ml/gcc-patches/2016-02/msg01036.html
> +ifeq ($(BR2_powerpc_e500mc):$(BR2_TOOLCHAIN_GCC_AT_LEAST_8),y:)
> +QT_CXXFLAGS += -mno-isel
> +endif

This looks good, but are you sure the problem is limited to e500mc ?
The e-mail at https://gcc.gnu.org/ml/gcc-patches/2016-02/msg01036.html
that you point says:

""
Target: e500v2 (I was able to reproduce with e500mc, e5500 targets as well).
""

So it would seem like e500mc is not the only affected target. So your
patch will fix the specific autobuilder failure because we happen to be
testing e500mc, but what about e500v2 (BR2_powerpc_8548) or
BR2_powerpc_e5500 ?

Interestingly, the last comment in
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60818 says that the patch
has been backported to gcc 6.x.

Best regards,

Thomas
-- 
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

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

* [Buildroot] [PATCH 1/1] qt: fix build on powerpc_e500mc
  2018-08-29 17:36 [Buildroot] [PATCH 1/1] qt: fix build on powerpc_e500mc Fabrice Fontaine
  2018-08-29 19:05 ` Thomas Petazzoni
@ 2018-09-01 21:30 ` Peter Korsgaard
  2018-09-01 21:32   ` Peter Korsgaard
  1 sibling, 1 reply; 4+ messages in thread
From: Peter Korsgaard @ 2018-09-01 21:30 UTC (permalink / raw)
  To: buildroot

>>>>> "Fabrice" == Fabrice Fontaine <fontaine.fabrice@gmail.com> writes:

 > gcc bug internal compiler error: in validate_condition_mode, at
 > config/rs6000/rs6000.c:180744. Bug is fixed since gcc 7.2.
 > Workaround is to set -mno-isel, see
 > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60818 and
 > https://gcc.gnu.org/ml/gcc-patches/2016-02/msg01036.html

 > Fixes:
 >  - http://autobuild.buildroot.net/results/9b9d11b3281a72c8f54fc675408acb96d24d8e7e

 > Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
 > ---
 >  package/qt/qt.mk | 9 +++++++++
 >  1 file changed, 9 insertions(+)

 > diff --git a/package/qt/qt.mk b/package/qt/qt.mk
 > index 1dcb05d6af..24ebbfdfdb 100644
 > --- a/package/qt/qt.mk
 > +++ b/package/qt/qt.mk
 > @@ -32,6 +32,15 @@ QT_LDFLAGS = $(TARGET_LDFLAGS)
 >  # use an older c++ standard to prevent build failure
 >  QT_CXXFLAGS += -std=gnu++98
 
 > +# gcc bug internal compiler error: in validate_condition_mode, at
 > +# config/rs6000/rs6000.c:180744. Bug is fixed since gcc 7.2.
 > +# Workaround is to set -mno-isel, see
 > +# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60818 and
 > +# https://gcc.gnu.org/ml/gcc-patches/2016-02/msg01036.html
 > +ifeq ($(BR2_powerpc_e500mc):$(BR2_TOOLCHAIN_GCC_AT_LEAST_8),y:)

If it is fixed in 7.2.0, why are we then using the workaround for 7.x as
well? Is this for external toolchains using 7.{0..1}.x? 7.2.0 was
released more than 1 year ago.

What is the impact of using -mno-isel? Performance? From googling, it
looks like a conditional move instruction:

https://www.rapitasystems.com/blog/interesting-microcontroller-features-powerpc-isel-instruction

-- 
Bye, Peter Korsgaard

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

* [Buildroot] [PATCH 1/1] qt: fix build on powerpc_e500mc
  2018-09-01 21:30 ` Peter Korsgaard
@ 2018-09-01 21:32   ` Peter Korsgaard
  0 siblings, 0 replies; 4+ messages in thread
From: Peter Korsgaard @ 2018-09-01 21:32 UTC (permalink / raw)
  To: buildroot

>>>>> "Peter" == Peter Korsgaard <peter@korsgaard.com> writes:

Hi,

 > If it is fixed in 7.2.0, why are we then using the workaround for 7.x as
 > well? Is this for external toolchains using 7.{0..1}.x? 7.2.0 was
 > released more than 1 year ago.

Sorry, I didn't notice that you had already sent a v2, fixing this.

-- 
Bye, Peter Korsgaard

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

end of thread, other threads:[~2018-09-01 21:32 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-08-29 17:36 [Buildroot] [PATCH 1/1] qt: fix build on powerpc_e500mc Fabrice Fontaine
2018-08-29 19:05 ` Thomas Petazzoni
2018-09-01 21:30 ` Peter Korsgaard
2018-09-01 21:32   ` Peter Korsgaard

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.