toolchain: GCC bug 68485
PATCH 1/2 toolchain: GCC bug 68485
GCC <= 9.x hangs while building brotli for the Microblaze Arch:
http://autobuild.buildroot.net/results/d86/d86251974a0a348a64d9a1d1fd7d02dd4aff0792/
Reported:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485
Still not fixed. Every Microblaze Gcc version <= 9.x is affected.
--- toolchain/Config.in | 6 ++++++ 1 file changed, 6 insertions(+)
toolchain/Config.in +6 -0
@@ -131,6 +131,12 @@ config BR2_TOOLCHAIN_HAS_GCC_BUG_64735 default y if !BR2_TOOLCHAIN_SUPPORTS_ALWAYS_LOCKFREE_ATOMIC_INTS && \ !BR2_TOOLCHAIN_GCC_AT_LEAST_7 +# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485. This bug still +# exists in gcc 9.x +config BR2_TOOLCHAIN_HAS_GCC_BUG_68485 + bool + default y if BR2_microblaze + # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85180. This bug no # longer exists in gcc 8.x. config BR2_TOOLCHAIN_HAS_GCC_BUG_85180
Signature · 1 line
2.17.1
PATCH 2/2 package/brotli: work aroung gcc bug 68485
With Microblaze Gcc version <= 9.x the build hangs due to gcc bug 68485:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485. The bug show up when building brotli with optimization but not when building with -O0. To work aroung this, if BR2_TOOLCHAIN_HAS_GCC_BUG_68458=y, we force using -O0.
Fixes:
http://autobuild.buildroot.net/results/d86/d86251974a0a348a64d9a1d1fd7d02dd4aff0792/
--- package/brotli/brotli.mk | 4 ++++ 1 file changed, 4 insertions(+)
package/brotli/brotli.mk +4 -0
@@ -14,4 +14,8 @@ BROTLI_CONF_OPTS = \ -DBROTLI_DISABLE_TESTS=ON \ -DBROTLI_BUNDLED_MODE=OFF +ifeq ($(BR2_TOOLCHAIN_HAS_GCC_BUG_68485),y) +BROTLI_CONF_OPTS += -DCMAKE_C_FLAGS="-O0" +endif + $(eval $(cmake-package))
Signature · 1 line
2.17.1
PATCH 2/2 package/brotli: work aroung gcc bug 68485
Quoted 1 line · Giulio Benetti
With Microblaze Gcc version <= 9.x the build hangs due to gcc bug 68485:
^^^^^
fails, not hangs
Quoted 19 lines
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485. The bug show up when building brotli with optimization but not when building with -O0. To work aroung this, if BR2_TOOLCHAIN_HAS_GCC_BUG_68458=y, we force using -O0.
Fixes:
http://autobuild.buildroot.net/results/d86/d86251974a0a348a64d9a1d1fd7d02dd4aff0792/
Signed-off-by Giulio Benetti <[email protected]>--- package/brotli/brotli.mk | 4 ++++ 1 file changed, 4 insertions(+)package/brotli/brotli.mk +0
-0
package/brotli/brotli.mk BROTLI_CONF_OPTS = \ · line 17
Quoted 4 lines
package/brotli/brotli.mk +1
-0@@ -14,4 +14,8 @@ BROTLI_CONF_OPTS = \ -DBROTLI_DISABLE_TESTS=ON \ -DBROTLI_BUNDLED_MODE=OFF +ifeq ($(BR2_TOOLCHAIN_HAS_GCC_BUG_68485),y)
Could you also update package/gpsd/gpsd.mk in the same way? It's the package
which triggered the original bug report, and it still disables it for microblaze entirely.
Regards,
Arnout
Quoted 5 lines
package/brotli/brotli.mk +3
-0+BROTLI_CONF_OPTS += -DCMAKE_C_FLAGS="-O0" +endif + $(eval $(cmake-package))
PATCH 2/2 package/brotli: work aroung gcc bug 68485
Il 27/05/2019 23:18, Arnout Vandecappelle ha scritto:
Quoted 6 lines · Giulio Benetti
Quoted 1 line
With Microblaze Gcc version <= 9.x the build hangs due to gcc bug 68485:
^^^^^fails, not hangs
Oops. Right.
Quoted 22 lines
Quoted 22 lines
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485. The bug show up when building brotli with optimization but not when building with -O0. To work aroung this, if BR2_TOOLCHAIN_HAS_GCC_BUG_68458=y, we force using -O0.
Fixes:
http://autobuild.buildroot.net/results/d86/d86251974a0a348a64d9a1d1fd7d02dd4aff0792/Signed-off-by Giulio Benetti <[email protected]>--- package/brotli/brotli.mk | 4 ++++ 1 file changed, 4 insertions(+)package/brotli/brotli.mk +0
-0@@ -14,4 +14,8 @@ BROTLI_CONF_OPTS = \ -DBROTLI_DISABLE_TESTS=ON \ -DBROTLI_BUNDLED_MODE=OFF
Quoted 6 lines
package/brotli/brotli.mk BROTLI_CONF_OPTS = \ · line 17
Quoted 1 line
package/brotli/brotli.mk +1
-0+ifeq ($(BR2_TOOLCHAIN_HAS_GCC_BUG_68485),y)Could you also update
package/gpsd/gpsd.mkin the same way? It's the package
which triggered the original bug report, and it still disables it for microblaze entirely.
Sure, it was already ready to tell the truth, but I have too many patches in WIP.
There are also, flann and libspatialindex.
I'm going to send all together then.
Thank you
Kind regards
Signature · 10 lines
Giulio Benetti CTO MICRONOVA SRL Sede: Via A. Niedda 3 - 35010 Vigonza (PD) Tel. 049/8931563 - Fax 049/8931346 Cod.Fiscale - P.IVA 02663420285 Capitale Sociale ? 26.000 i.v. Iscritta al Reg. Imprese di Padova N. 02663420285 Numero R.E.A. 258642
Quoted 6 lines
Quoted 6 lines
package/brotli/brotli.mk +3
-0+BROTLI_CONF_OPTS += -DCMAKE_C_FLAGS="-O0" +endif + $(eval $(cmake-package))
v2 cover Fix and clean GCC BUG 68485 per-package
Introduce Gcc Bug 68485
Fix Bug 68485 for brotli
Clean up packages for:
- gpsd
- flann
- libspatialindex
Giulio Benetti (4):
package/brotli: work aroung gcc bug 68485 package/gpsd: use common BR2_TOOLCHAIN_HAS_GCC_BUG_68485 package/flann: re-enable package on Microblaze package/libspatialindex: use common BR2_TOOLCHAIN_HAS_BUG_68485
package/brotli/brotli.mk | 4 ++++ package/flann/Config.in | 4 ---- package/flann/flann.mk | 4 ++++ package/gpsd/gpsd.mk | 5 +---- package/libspatialindex/libspatialindex.mk | 4 +--- 5 files changed, 10 insertions(+), 11 deletions(-)
Signature · 1 line
2.17.1
PATCH v2 1/4 package/brotli: work aroung gcc bug 68485
With Microblaze Gcc version <= 9.x the build fails due to gcc bug 68485:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485. The bug show up when building brotli with optimization but not when building with -O0. To work aroung this, if BR2_TOOLCHAIN_HAS_GCC_BUG_68458=y, we force using -O0.
Fixes:
http://autobuild.buildroot.net/results/d86/d86251974a0a348a64d9a1d1fd7d02dd4aff0792/
--- package/brotli/brotli.mk | 4 ++++ 1 file changed, 4 insertions(+)
package/brotli/brotli.mk +4 -0
@@ -14,4 +14,8 @@ BROTLI_CONF_OPTS = \ -DBROTLI_DISABLE_TESTS=ON \ -DBROTLI_BUNDLED_MODE=OFF +ifeq ($(BR2_TOOLCHAIN_HAS_GCC_BUG_68485),y) +BROTLI_CONF_OPTS += -DCMAKE_C_FLAGS="-O0" +endif + $(eval $(cmake-package))
Signature · 1 line
2.17.1
Arnout Vandecappelle
AppliedPATCH v2 1/4 package/brotli: work aroung gcc bug 68485
Quoted 11 lines · Giulio Benetti
With Microblaze Gcc version <= 9.x the build fails due to gcc bug 68485:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485. The bug show up when building brotli with optimization but not when building with -O0. To work aroung this, if BR2_TOOLCHAIN_HAS_GCC_BUG_68458=y, we force using -O0.Fixes:
http://autobuild.buildroot.net/results/d86/d86251974a0a348a64d9a1d1fd7d02dd4aff0792/
Signed-off-by Giulio Benetti <[email protected]>
Applied to master, thanks.
The rest of the series should go to next, actually. In fact, I should also have
applied flare-engine to next :-(
Regards,
Arnout
Quoted 18 lines
--- package/brotli/brotli.mk | 4 ++++ 1 file changed, 4 insertions(+)package/brotli/brotli.mk +4
-0@@ -14,4 +14,8 @@ BROTLI_CONF_OPTS = \ -DBROTLI_DISABLE_TESTS=ON \ -DBROTLI_BUNDLED_MODE=OFF +ifeq ($(BR2_TOOLCHAIN_HAS_GCC_BUG_68485),y) +BROTLI_CONF_OPTS += -DCMAKE_C_FLAGS="-O0" +endif + $(eval $(cmake-package))
PATCH v2 1/4 package/brotli: work aroung gcc bug 68485
Il 28/05/2019 00:11, Arnout Vandecappelle ha scritto:
Quoted 11 lines · Giulio Benetti
Quoted 8 lines
With Microblaze Gcc version <= 9.x the build fails due to gcc bug 68485:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485. The bug show up when building brotli with optimization but not when building with -O0. To work aroung this, if BR2_TOOLCHAIN_HAS_GCC_BUG_68458=y, we force using -O0.Fixes:
Quoted 8 lines
Quoted 3 lines
http://autobuild.buildroot.net/results/d86/d86251974a0a348a64d9a1d1fd7d02dd4aff0792/Signed-off-by Giulio Benetti <[email protected]>Applied to master, thanks.
The rest of the series should go to next, actually. In fact, I should also have
applied flare-engine to next :-(
Sure, no problem, I have lot of other Microblaze patches. Tomorrow I will give priority to bug fix patches and only after to "clean-up" patches.
Kind regards
Signature · 10 lines
Giulio Benetti CTO MICRONOVA SRL Sede: Via A. Niedda 3 - 35010 Vigonza (PD) Tel. 049/8931563 - Fax 049/8931346 Cod.Fiscale - P.IVA 02663420285 Capitale Sociale ? 26.000 i.v. Iscritta al Reg. Imprese di Padova N. 02663420285 Numero R.E.A. 258642
Quoted 19 lines
Quoted 19 lines
--- package/brotli/brotli.mk | 4 ++++ 1 file changed, 4 insertions(+)package/brotli/brotli.mk +4
-0@@ -14,4 +14,8 @@ BROTLI_CONF_OPTS = \ -DBROTLI_DISABLE_TESTS=ON \ -DBROTLI_BUNDLED_MODE=OFF +ifeq ($(BR2_TOOLCHAIN_HAS_GCC_BUG_68485),y) +BROTLI_CONF_OPTS += -DCMAKE_C_FLAGS="-O0" +endif + $(eval $(cmake-package))
PATCH v2 1/4 package/brotli: work aroung gcc bug 68485
Arnout,
Il 28/05/2019 00:17, Giulio Benetti ha scritto:
Quoted 20 lines
Il 28/05/2019 00:11, Arnout Vandecappelle ha scritto:
Quoted 19 lines · Giulio Benetti
Quoted 11 lines
With Microblaze Gcc version <= 9.x the build fails due to gcc bug 68485:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485. The bug show up when building brotli with optimization but not when building with -O0. To work aroung this, if BR2_TOOLCHAIN_HAS_GCC_BUG_68458=y, we force using -O0.Fixes:
http://autobuild.buildroot.net/results/d86/d86251974a0a348a64d9a1d1fd7d02dd4aff0792/Signed-off-by Giulio Benetti <[email protected]>Applied to master, thanks.
The rest of the series should go to next, actually. In fact, I should also have
applied flare-engine to next :-(
Need also this patch, otherwise build is broken:
https://patchwork.ozlabs.org/patch/1105947/
I've forgot to resend it!
Signature · 10 lines
Giulio Benetti CTO MICRONOVA SRL Sede: Via A. Niedda 3 - 35010 Vigonza (PD) Tel. 049/8931563 - Fax 049/8931346 Cod.Fiscale - P.IVA 02663420285 Capitale Sociale ? 26.000 i.v. Iscritta al Reg. Imprese di Padova N. 02663420285 Numero R.E.A. 258642
PATCH v2 2/4 package/gpsd: use common BR2_TOOLCHAIN_HAS_GCC_BUG_68485
In reply to Giulio BenettiWorkaround for Gcc ICE works ok, but it's issued if BR2_microblaze=y with a local comment. Let's use BR2_TOOLCHAIN_HAS_GCC_BUG_68485 instead to avoid repeating ICE bug comment for every package affected from it.
--- package/gpsd/gpsd.mk | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-)
package/gpsd/gpsd.mk +1 -4
@@ -42,10 +42,7 @@ else GPSD_SCONS_OPTS += libgpsmm=no endif -# prevents from triggering GCC ICE -# A bug was reported to the gcc bug tracker: -# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485 -ifeq ($(BR2_microblaze),y) +ifeq ($(BR2_TOOLCHAIN_HAS_GCC_BUG_68485),y) GPSD_CFLAGS += -O0 endif
Signature · 1 line
2.17.1
PATCH v2 3/4 package/flann: re-enable package on Microblaze
In reply to Giulio BenettiWith Microblaze Gcc version <= 9.x build fails tue to bug 68485:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485. To avoid this, the flann package has a !BR2_microblaze dependency. However, gcc bug 68485 only triggers when optimization is enabled, so we can work around the issue by passing -O0, which is what we do in other Buildroot packages to work around this bug.
So, this commit passes -O0 when BR2_TOOLCHAIN_HAS_GCC_BUG_68485, and re-enables flann on Microblaze.
--- package/flann/Config.in | 4 ---- package/flann/flann.mk | 4 ++++ 2 files changed, 4 insertions(+), 4 deletions(-)
package/flann/Config.in +0 -4
@@ -2,9 +2,6 @@ config BR2_PACKAGE_FLANN bool "flann" depends on BR2_INSTALL_LIBSTDCPP depends on !BR2_STATIC_LIBS - # all gcc versions fail to build flann on Microblaze due to - # gcc bug https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69401 - depends on !BR2_microblaze help FLANN is a library for performing fast approximate nearest neighbor searches in high dimensional spaces. It contains a
@@ -25,5 +22,4 @@ config BR2_PACKAGE_FLANN_EXAMPLES endif comment "flann needs a toolchain w/ C++, dynamic library" - depends on !BR2_microblaze depends on !BR2_INSTALL_LIBSTDCPP || BR2_STATIC_LIBS
package/flann/flann.mk +4 -0
@@ -18,4 +18,8 @@ FLANN_CONF_OPTS = \ -DPYTHON_EXECUTABLE=OFF \ -DCMAKE_DISABLE_FIND_PACKAGE_HDF5=TRUE +ifeq ($(BR2_TOOLCHAIN_HAS_GCC_BUG_68485),y) +FLANN_CONF_OPTS += -DCMAKE_CXX_FLAGS="$(TARGET_CXXFLAGS) -O0" +endif + $(eval $(cmake-package))
Signature · 1 line
2.17.1
PATCH v2 4/4 package/libspatialindex: use common BR2_TOOLCHAIN_HAS_BUG_68485
In reply to Giulio BenettiFor consistency with the rest of packages let's use common BR2_TOOLCHAIN_HAS_BUG_68485 instead of !BR2_microblaze condition with comment on top of it.
--- package/libspatialindex/libspatialindex.mk | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
package/libspatialindex/libspatialindex.mk +1 -3
@@ -17,9 +17,7 @@ LIBSPATIALINDEX_AUTORECONF = YES LIBSPATIALINDEX_CXXFLAGS = $(TARGET_CXXFLAGS) LIBSPATIALINDEX_CONF_ENV = CXXFLAGS="$(LIBSPATIALINDEX_CXXFLAGS)" -# Workaround gcc ICE -# (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485) -ifeq ($(BR2_microblaze),y) +ifeq ($(BR2_TOOLCHAIN_HAS_GCC_BUG_68485),y) LIBSPATIALINDEX_CXXFLAGS += -O0 endif
Signature · 1 line
2.17.1
Arnout Vandecappelle
AppliedPATCH 1/2 toolchain: GCC bug 68485
In reply to Giulio BenettiQuoted 9 lines · Giulio Benetti
GCC <= 9.x hangs while building brotli for the Microblaze Arch:
http://autobuild.buildroot.net/results/d86/d86251974a0a348a64d9a1d1fd7d02dd4aff0792/Reported:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485Still not fixed. Every Microblaze Gcc version <= 9.x is affected.
Signed-off-by Giulio Benetti <[email protected]>
Applied to master (with a little rewording of the commit message), thanks.
I should have noticed that this was missing :-(
Regards,
Arnout
Quoted 22 lines
--- toolchain/Config.in | 6 ++++++ 1 file changed, 6 insertions(+)toolchain/Config.in +6
-0@@ -131,6 +131,12 @@ config BR2_TOOLCHAIN_HAS_GCC_BUG_64735 default y if !BR2_TOOLCHAIN_SUPPORTS_ALWAYS_LOCKFREE_ATOMIC_INTS && \ !BR2_TOOLCHAIN_GCC_AT_LEAST_7 +# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485. This bug still +# exists in gcc 9.x +config BR2_TOOLCHAIN_HAS_GCC_BUG_68485 + bool + default y if BR2_microblaze + # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85180. This bug no # longer exists in gcc 8.x. config BR2_TOOLCHAIN_HAS_GCC_BUG_85180
PATCH 1/2 toolchain: GCC bug 68485
Il 28/05/2019 09:54, Arnout Vandecappelle ha scritto:
Quoted 9 lines · Giulio Benetti
Quoted 6 lines
GCC <= 9.x hangs while building brotli for the Microblaze Arch:
http://autobuild.buildroot.net/results/d86/d86251974a0a348a64d9a1d1fd7d02dd4aff0792/
Quoted 7 lines
Quoted 3 lines
Still not fixed. Every Microblaze Gcc version <= 9.x is affected.
Signed-off-by Giulio Benetti <[email protected]>Applied to master (with a little rewording of the commit message), thanks.
I should have noticed that this was missing :-(
No problem, I've catched it!
There are a lot of patche for Microblaze now so sometimes it's confusing ;)
Signature · 10 lines
Giulio Benetti CTO MICRONOVA SRL Sede: Via A. Niedda 3 - 35010 Vigonza (PD) Tel. 049/8931563 - Fax 049/8931346 Cod.Fiscale - P.IVA 02663420285 Capitale Sociale ? 26.000 i.v. Iscritta al Reg. Imprese di Padova N. 02663420285 Numero R.E.A. 258642
Quoted 23 lines
Quoted 23 lines
--- toolchain/Config.in | 6 ++++++ 1 file changed, 6 insertions(+)toolchain/Config.in +6
-0@@ -131,6 +131,12 @@ config BR2_TOOLCHAIN_HAS_GCC_BUG_64735 default y if !BR2_TOOLCHAIN_SUPPORTS_ALWAYS_LOCKFREE_ATOMIC_INTS && \ !BR2_TOOLCHAIN_GCC_AT_LEAST_7 +# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485. This bug still +# exists in gcc 9.x +config BR2_TOOLCHAIN_HAS_GCC_BUG_68485 + bool + default y if BR2_microblaze + # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85180. This bug no # longer exists in gcc 8.x. config BR2_TOOLCHAIN_HAS_GCC_BUG_85180
PATCH 1/2 toolchain: GCC bug 68485
In reply to Giulio BenettiQuoted 11 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Giulio" == Giulio Benetti <[email protected]> writes:
GCC <= 9.x hangs while building brotli for the Microblaze Arch:
http://autobuild.buildroot.net/results/d86/d86251974a0a348a64d9a1d1fd7d02dd4aff0792/Reported:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485Still not fixed. Every Microblaze Gcc version <= 9.x is affected.
Signed-off-by Giulio Benetti <[email protected]>
Committed to 2019.02.x, thanks.
Signature · 1 line
Bye, Peter Korsgaard