Gentoolto: media-libs/dav1d doesn't build with graphite

Created on 17 Nov 2019  Â·  34Comments  Â·  Source: InBetweenNames/gentooLTO

-O2 -fno-stack-protector -march=native -falign-functions=32 -O3 -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=1 -fuse-linker-plugin -Wl,-O1 -Wl,--as-needed -Wl,-O1 -Wl,--as-needed -O2 -fno-stack-protector -march=native -falign-functions=32 -O3 -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=1 -fuse-linker-plugin -pthread -Wl,--start-group -lm -Wl,--end-group
during GIMPLE pass: graphite
../dav1d-0.5.1/tests/checkasm/looprestoration.c: In function ‘check_sgr.isra.0’:
../dav1d-0.5.1/tests/checkasm/looprestoration.c:118:13: internal compiler error: Segmentation fault
  118 | static void check_sgr(Dav1dLoopRestorationDSPContext *const c) {
      |             ^

Disabling graphite fixes the issue and makes dav1d compile correctly.

Most helpful comment

reported to gentoo bugs as https://bugs.gentoo.org/702968
was on the fence as it might be an isl issue, but then I noticed dav1d and the scipy minimal testcase both compile successfully with gcc-8.3.0. I guess I'll see what the devs have to say.

All 34 comments

I have had no troubles compiling with bfd nor gold. Can you post the full build.log and your build env? GCC, binutils, etc

=================================================================
                        Package Settings
=================================================================

media-libs/dav1d-0.5.1::gentoo was built with the following:
USE="10bit 8bit asm" ABI_X86="(64) -32 (-x32)"
CFLAGS="-O3 -march=native -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fno-plt -fipa-pta -fno-semantic-interposition -fno-math-errno -fno-trapping-math -flto=12 -malign-data=cacheline -pipe -fuse-ld=bfd -falign-functions=32 -Wl,-O1 -Wl,--as-needed"
CXXFLAGS="-O3 -march=native -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fno-plt -fipa-pta -fno-semantic-interposition -fno-math-errno -fno-trapping-math -flto=12 -malign-data=cacheline -pipe -fuse-ld=bfd -falign-functions=32 -Wl,-O1 -Wl,--as-needed"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -O3 -march=native -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fno-plt -fipa-pta -fno-semantic-interposition -fno-math-errno -fno-trapping-math -flto=12 -malign-data=cacheline -pipe -fuse-ld=bfd -falign-functions=32"

There was a recent isl version bump. Have you rebuilt GCC after upgrading dev-libs/isl?

Seconded.

~~~ bash

Package Settings

media-libs/dav1d-0.5.1::gentoo was built with the following:
USE="10bit 8bit asm" ABI_X86="32 (64) -x32"
CFLAGS="-O3 -march=bdver4 -pipe -pthread -fira-hoist-pressure -fira-loop-pressure -fbranch-target-load-optimize -fweb -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=2 -fuse-linker-plugin -fuse-ld=bfd -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3"
CXXFLAGS="-O3 -march=bdver4 -pipe -pthread -fira-hoist-pressure -fira-loop-pressure -fbranch-target-load-optimize -fweb -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=2 -fuse-linker-plugin -fuse-ld=bfd -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3"
LDFLAGS="-O3 -march=bdver4 -pipe -pthread -fira-hoist-pressure -fira-loop-pressure -fbranch-target-load-optimize -fweb -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=2 -fuse-linker-plugin -fuse-ld=bfd -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3"
~~~

Here you go. Will try recompiling gcc later.
build.log
info.txt
pqv.txt
env.txt

Hm... Which linker are you using?

Recompiling gcc didn't solve the issue.
How do I know which linker I'm using? :)

Was using gold but fails with bfd too.

media-libs/dav1d-0.5.1::gentoo was built with the following:
USE="10bit 8bit asm" ABI_X86="(64) -32 (-x32)"
CFLAGS="-O2 -fno-stack-protector -fno-stack-check -fomit-frame-pointer -march=native -falign-functions=32 -O3 -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=1 -fuse-linker-plugin -Wl,-O1 -Wl,--as-needed"
CXXFLAGS="-O2 -fno-stack-protector -fno-stack-check -fomit-frame-pointer -march=native -falign-functions=32 -O3 -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=1 -fuse-linker-plugin -Wl,-O1 -Wl,--as-needed"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -O2 -fno-stack-protector -fno-stack-check -fomit-frame-pointer -march=native -falign-functions=32 -O3 -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=1 -fuse-linker-plugin"

I am still unable to reproduce your graphite issue. Maybe try rebuilding binutils for linking and glibc because it's linking libm (both with sane FLAGS).

To check, ld -v. GNU ld is ld.bfd, GNU gold is ld.gold. Use binutils-config --linker ld.bfd to switch between bfd or gold. -fuse-ld=* will override that, but maybe not all the time, for ex. the kernel.

@jiblime Since we're not talking about compiling the kernel, I think that -fuse-ld=[linker name goes here] is enough. It's certainly easier to tell from the flags which linker is being used if it is explicitly being declared in the flags.

@ElDavoo I second jiblime's advice.

No luck with both linkers.
I'm sorry you can't reproduce it. This is getting more and more obscure.

I can reproduce. I'm currently doing a world rebuild and see if that will fix it

see if that will fix it

It didn't. Very similar build.log:
build.log

I'll note that during the world rebuild the currently installed version, =media-libs/dav1d-0.4.0, also failed to compile. It was installed on August 19 and I'm pretty sure I have graphite on at the time.

@zhuyifei1999 , @ElDavoo , what processors are you building on?

@jiblime From their build logs:

~~~ bash

  • Linux zhuyifei1999-ThinkPad-T480 5.3.7 #8 SMP Wed Oct 30 21:53:11 CDT 2019 x86_64 Intel(R) Core(TM) i5-8250U CPU @ 1.60GHz GenuineIntel GNU/Linux
  • Linux lenuovo 5.3.11-gentoo #1 SMP PREEMPT Thu Nov 14 10:57:34 CET 2019 x86_64 Intel(R) Pentium(R) CPU N3520 @ 2.16GHz GenuineIntel GNU/Linux
    ~~~

@zhuyifei1999 * LDFLAGS='-Wl,-O1 -Wl,--as-needed -Wl,--hash-style=gnu -march=native -O3 -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=7 -fuse-linker-plugin -falign-functions=32 -pipe -ggdb'

-ggdb

Why!?

-ggdb

Why!?

I debug random stuffs a lot, when I get the time to. Heh. It rarely cause any issue except memory & disk usage during some compilation.

so?

@jiblime

looks like no one has tested rebuilding gcc against isl-0.21 yet? I'll give it a shot after my current world rebuild finishes.

--- a/meson_options.txt
+++ b/meson_options.txt
@@ -22,7 +22,7 @@

 option('enable_tests',
     type: 'boolean',
-    value: true,
+    value: false,
     description: 'Build dav1d tests')

 option('logging',

downgrading to isl-0.21 fixes both this and the #450 GRAPHITE ICE. this is a gcc graphite regression.

Good thing that I didn't have to build Dav1d recently then. So... Who's gonna report this to GNU?

account creation on the GCC bugzilla is currently restricted, but I've requested an account. otherwise, I believe @InBetweenNames has filed gcc bugs before.

Fingers crossed!

In the meantime I'd like to you inform you that dav1d 0.5.2 doesn't compile.

@ElDavoo until the gcc bug is fixed, media-libs/dav1d *FLAGS-="${GRAPHITE}" is necessary.

We could check in this work around and tag it with this bug ID, then remove it when the bug can be resolved.

@wolfwood
Do you really need those tests to be optimized? Or do you need those tests? Build them separately.

Or it's only usage for media-libs/dav1d for now ?
I don't know, because I built it out of curiosity, w/ emerge -1B ...

EDIT: Sorry, I'm tired, I'm asking stupid questions here and there tonight, so clarification:
I know it should be reported, but there was several strings right after the output. Like "report this to bugs.gentoo.org". There are people who maintain GCC-family bugs. So (I mean you should) try to report and apply gentoo-like solution fof this time.

@pchome I'm more interested in #450 but it seems that this is the same underlying issue in gcc

for this, sure throw tests under a use flag, off by default.

dav1d-0.5.2:20191214-042057_nocolor.log
No issues here.

media-libs/dav1d-0.5.2

media-libs/dav1d-0.5.2::gentoo was built with the following:
USE="10bit 8bit asm" ABI_X86="(64) -32 (-x32)"
CFLAGS="-O3 -march=native -fgraphite-identity -floop-nest-optimize -fipa-pta -fdevirtualize-at-ltrans -fno-semantic-interposition -flto -flimit-function-alignment -minline-stringops-dynamically -pipe -fuse-linker-plugin -Wl,-O1 -Wl,--as-needed"
CXXFLAGS="-O3 -march=native -fgraphite-identity -floop-nest-optimize -fipa-pta -fdevirtualize-at-ltrans -fno-semantic-interposition -flto -flimit-function-alignment -minline-stringops-dynamically -pipe -fuse-linker-plugin -Wl,-O1 -Wl,--as-needed"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -O3 -march=native -fgraphite-identity -floop-nest-optimize -fipa-pta -fdevirtualize-at-ltrans -fno-semantic-interposition -flto -flimit-function-alignment -minline-stringops-dynamically -pipe -fuse-linker-plugin"

sys-devel/gcc-9.2.0

Note: I explicitly declare -march=znver2 instead of native because there are some strange parts of GCC that doesn't use native as an arch. Example being gccjit. I also have custom patches but I don't think they are related. Mention me if you would like me to upload them, otherwise I'll forget

sys-devel/gcc-9.2.0-r2::local was built with the following:
USE="custom-cflags (cxx) fortran graphite lto (multilib) nls nptl objc openmp pch pgo sanitize ssp test (-altivec) -d -debug -doc (-fixed-point) -go (-hardened) -jit (-libssp) -objc++ -objc-gc -pie -systemtap -vanilla -vtv" ABI_X86="(64)"
CFLAGS="-O3 -march=znver2 -fgraphite-identity -floop-nest-optimize -fno-semantic-interposition -flimit-function-alignment --param=max-unroll-times=4 -fno-signed-zeros -fno-trapping-math -D__FAST_MATH__=1 -minline-stringops-dynamically -maccumulate-outgoing-args -pipe -fopt-info-vec-loop"
CXXFLAGS="-O3 -march=znver2 -fgraphite-identity -floop-nest-optimize -fno-semantic-interposition -flimit-function-alignment --param=max-unroll-times=4 -fno-signed-zeros -fno-trapping-math -D__FAST_MATH__=1 -minline-stringops-dynamically -maccumulate-outgoing-args -pipe -fopt-info-vec-loop"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs candy config-protect-if-modified distlocks fixlafiles ipc-sandbox keepwork merge-sync multilib-strict network-sandbox news parallel-fetch parallel-install pid-sandbox preserve-libs protect-owned sandbox sfperms split-elog split-log strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"

dev-libs/isl-0.22

dev-libs/isl-0.22::gentoo was built with the following:
USE="-static-libs" ABI_X86="32 (64) (-x32)"
CFLAGS="-O3 -march=native -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fno-semantic-interposition -fno-math-errno -fno-trapping-math -flto -pipe -falign-functions=32 -fuse-linker-plugin -Wl,-O1 -Wl,--as-needed"
CXXFLAGS="-O3 -march=native -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fno-semantic-interposition -fno-math-errno -fno-trapping-math -flto -pipe -falign-functions=32 -fuse-linker-plugin -Wl,-O1 -Wl,--as-needed"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs candy config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch parallel-install pid-sandbox preserve-libs protect-owned sandbox sfperms split-elog split-log strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -O3 -march=native -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fno-semantic-interposition -fno-math-errno -fno-trapping-math -flto -pipe -falign-functions=32 -fuse-linker-plugin"

dev-util/meson-0.52.0

dev-util/meson-0.52.0::gentoo was built with the following:
USE="-test" ABI_X86="(64)" PYTHON_TARGETS="python3_6 python3_7 -python3_5"
CFLAGS="-O3 -march=native -fgraphite-identity -floop-nest-optimize -fipa-pta -fdevirtualize-at-ltrans -fno-semantic-interposition -fno-math-errno -fno-trapping-math -flto -flimit-function-alignment -minline-stringops-dynamically -pipe -fuse-linker-plugin -Wl,-O1 -Wl,--as-needed -Wl,-z,now"
CXXFLAGS="-O3 -march=native -fgraphite-identity -floop-nest-optimize -fipa-pta -fdevirtualize-at-ltrans -fno-semantic-interposition -fno-math-errno -fno-trapping-math -flto -flimit-function-alignment -minline-stringops-dynamically -pipe -fuse-linker-plugin -Wl,-O1 -Wl,--as-needed -Wl,-z,now"
FEATURES="pid-sandbox fixlafiles binpkg-logs unmerge-orphans distlocks protect-owned candy usersandbox parallel-install sfperms network-sandbox split-log unknown-features-warn multilib-strict news binpkg-dostrip assume-digests userfetch ipc-sandbox sandbox binpkg-docompress unmerge-logs preserve-libs split-elog xattr usersync config-protect-if-modified strict parallel-fetch userpriv merge-sync"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,-z,now -O3 -march=native -fgraphite-identity -floop-nest-optimize -fipa-pta -fdevirtualize-at-ltrans -fno-semantic-interposition -fno-math-errno -fno-trapping-math -flto -flimit-function-alignment -minline-stringops-dynamically -pipe -fuse-linker-plugin"

dev-util/ninja-1.9.0

dev-util/ninja-1.9.0::gentoo was built with the following:
USE="-doc -emacs -test -vim-syntax" ABI_X86="(64)"
CFLAGS="-O3 -march=native -fipa-pta -fdevirtualize-at-ltrans -fno-semantic-interposition -flto -flimit-function-alignment -pipe -fuse-linker-plugin -Wl,-O1 -Wl,--as-needed"
CXXFLAGS="-O3 -march=native -fipa-pta -fdevirtualize-at-ltrans -fno-semantic-interposition -flto -flimit-function-alignment -pipe -fuse-linker-plugin -Wl,-O1 -Wl,--as-needed"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -O3 -march=native -fipa-pta -fdevirtualize-at-ltrans -fno-semantic-interposition -flto -flimit-function-alignment -pipe -fuse-linker-plugin"

dev-lang/nasm-2.14.02

dev-lang/nasm-2.14.02::gentoo was built with the following:
USE="-doc" ABI_X86="(64)"
CFLAGS="-march=native -pipe -Wl,-O1 -Wl,--as-needed -O2"
CXXFLAGS="-march=native -pipe -Wl,-O1 -Wl,--as-needed -O2"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs candy config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch parallel-install pid-sandbox preserve-libs protect-owned sandbox sfperms split-elog split-log strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -march=native -pipe -O2"

So... 0.5.2 fails, but only for the 64-bit library. Building the 32-bit library does not cause this error.

~~~ bash

*

Package Settings

dev-libs/isl-0.22::gentoo was built with the following:
USE="-static-libs" ABI_X86="32 (64) -x32"
CFLAGS="-O3 -march=bdver4 -pipe -pthread -fira-hoist-pressure -fira-loop-pressure -fbranch-target-load-optimize -fweb -ftracer -fsched2-use-superblocks -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=2 -fuse-linker-plugin -fuse-ld=bfd -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3"
CXXFLAGS="-O3 -march=bdver4 -pipe -pthread -fira-hoist-pressure -fira-loop-pressure -fbranch-target-load-optimize -fweb -ftracer -fsched2-use-superblocks -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=2 -fuse-linker-plugin -fuse-ld=bfd -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3"
LDFLAGS="-O3 -march=bdver4 -pipe -pthread -fira-hoist-pressure -fira-loop-pressure -fbranch-target-load-optimize -fweb -ftracer -fsched2-use-superblocks -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=2 -fuse-linker-plugin -fuse-ld=bfd -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3"

dev-util/meson-0.52.0::gentoo was built with the following:
USE="-test" ABI_X86="(64)" PYTHON_TARGETS="python3_6 python3_7 -python3_5"
CFLAGS="-O3 -march=bdver4 -falign-functions=32 -falign-jumps=32:8:8 -falign-loops=32:25:8 -pipe -pthread -fira-hoist-pressure -fira-loop-pressure -fbranch-target-load-optimize -fweb -ftracer -fsched2-use-superblocks -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -fno-plt -flto=2 -fuse-linker-plugin -fuse-ld=bfd -fstack-protector-all -fstack-clash-protection -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3 -Wl,-z,relro -Wl,-z,now"
CXXFLAGS="-O3 -march=bdver4 -falign-functions=32 -falign-jumps=32:8:8 -falign-loops=32:25:8 -pipe -pthread -fira-hoist-pressure -fira-loop-pressure -fbranch-target-load-optimize -fweb -ftracer -fsched2-use-superblocks -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -fno-plt -flto=2 -fuse-linker-plugin -fuse-ld=bfd -fstack-protector-all -fstack-clash-protection -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3 -Wl,-z,relro -Wl,-z,now"
FEATURES="usersandbox sandbox ebuild-locks unmerge-logs merge-sync strict assume-digests usersync protect-owned ipc-sandbox unknown-features-warn distlocks pid-sandbox news network-sandbox userpriv binpkg-logs binpkg-docompress unmerge-orphans userfetch parallel-fetch multilib-strict binpkg-dostrip config-protect-if-modified preserve-libs sfperms xattr fixlafiles"

sys-devel/gcc-8.3.0-r3::gentoo was built with the following:
USE="(cxx) fortran graphite hardened (multilib) nls nptl openmp pch (pie) sanitize ssp systemtap vtv (-altivec) -debug -doc (-fixed-point) -go (-jit) (-libssp) -mpx -objc -objc++ -objc-gc -pgo -test -vanilla" ABI_X86="(64)"
CFLAGS="-march=bdver4 -pipe -fuse-ld=bfd -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3 -O2"
CXXFLAGS="-march=bdver4 -pipe -fuse-ld=bfd -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3 -O2"
FEATURES="userfetch protect-owned sfperms xattr network-sandbox strict binpkg-logs binpkg-dostrip usersync multilib-strict distlocks ebuild-locks news usersandbox fixlafiles assume-digests parallel-fetch binpkg-docompress ipc-sandbox config-protect-if-modified preserve-libs pid-sandbox unmerge-logs merge-sync unmerge-orphans unknown-features-warn userpriv sandbox"
LDFLAGS="-march=bdver4 -pipe -fuse-ld=bfd -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3 -O2"

sys-devel/gcc-9.2.0-r2::gentoo was built with the following:
USE="(cxx) fortran go graphite hardened lto (multilib) nls nptl openmp pch (pie) sanitize ssp systemtap vtv (-altivec) -d -debug -doc (-fixed-point) (-jit) (-libssp) -objc -objc++ -objc-gc -pgo -test -vanilla" ABI_X86="(64)"
CFLAGS="-march=bdver4 -pipe -fuse-ld=bfd -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3 -O2"
CXXFLAGS="-march=bdver4 -pipe -fuse-ld=bfd -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3 -O2"
FEATURES="userfetch protect-owned sfperms xattr network-sandbox strict binpkg-logs binpkg-dostrip usersync multilib-strict distlocks ebuild-locks news usersandbox fixlafiles assume-digests parallel-fetch binpkg-docompress ipc-sandbox config-protect-if-modified preserve-libs pid-sandbox unmerge-logs merge-sync unmerge-orphans unknown-features-warn userpriv sandbox"
LDFLAGS="-march=bdver4 -pipe -fuse-ld=bfd -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3 -O2"

dev-util/ninja-1.9.0::gentoo was built with the following:
USE="vim-syntax -doc -emacs -test" ABI_X86="(64)"
CFLAGS="-O3 -march=bdver4 -pipe -pthread -fopenmp -fira-hoist-pressure -fira-loop-pressure -fbranch-target-load-optimize -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=3 -fuse-linker-plugin -fuse-ld=bfd -Wall -Wextra -Wno-error -Wl,-O1 -Wl,--as-needed -Wl,-O3"
CXXFLAGS="-O3 -march=bdver4 -pipe -pthread -fopenmp -fira-hoist-pressure -fira-loop-pressure -fbranch-target-load-optimize -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=3 -fuse-linker-plugin -fuse-ld=bfd -Wall -Wextra -Wno-error -Wl,-O1 -Wl,--as-needed -Wl,-O3"
LDFLAGS="-O3 -march=bdver4 -pipe -pthread -fopenmp -fira-hoist-pressure -fira-loop-pressure -fbranch-target-load-optimize -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=3 -fuse-linker-plugin -fuse-ld=bfd -Wall -Wextra -Wno-error -Wl,-O1 -Wl,--as-needed -Wl,-O3"

dev-lang/nasm-2.14.02::gentoo was built with the following:
USE="-doc" ABI_X86="(64)"
CFLAGS="-march=bdver4 -pipe -fuse-ld=bfd -Wall -Wextra -Wno-error -Wl,-O1 -Wl,--as-needed -Wl,-O3 -O2"
CXXFLAGS="-march=bdver4 -pipe -fuse-ld=bfd -Wall -Wextra -Wno-error -Wl,-O1 -Wl,--as-needed -Wl,-O3 -O2"
LDFLAGS="-march=bdver4 -pipe -fuse-ld=bfd -Wall -Wextra -Wno-error -Wl,-O1 -Wl,--as-needed -Wl,-O3 -O2"

*

Package Settings

media-libs/dav1d-0.5.2::gentoo was built with the following:
USE="10bit 8bit asm" ABI_X86="32 (64) -x32"
CFLAGS="-O3 -march=bdver4 -falign-functions=32 -falign-jumps=32:8:8 -falign-loops=32:25:8 -pipe -pthread -fira-hoist-pressure -fira-loop-pressure -fbranch-target-load-optimize -fweb -ftracer -fsched2-use-superblocks -fgraphite-identity -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -fno-plt -flto=2 -fuse-linker-plugin -fuse-ld=bfd -fstack-protector-all -fstack-clash-protection -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3 -Wl,-z,relro -Wl,-z,now"
CXXFLAGS="-O3 -march=bdver4 -falign-functions=32 -falign-jumps=32:8:8 -falign-loops=32:25:8 -pipe -pthread -fira-hoist-pressure -fira-loop-pressure -fbranch-target-load-optimize -fweb -ftracer -fsched2-use-superblocks -fgraphite-identity -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -fno-plt -flto=2 -fuse-linker-plugin -fuse-ld=bfd -fstack-protector-all -fstack-clash-protection -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3 -Wl,-z,relro -Wl,-z,now"
LDFLAGS="-O3 -march=bdver4 -falign-functions=32 -falign-jumps=32:8:8 -falign-loops=32:25:8 -pipe -pthread -fira-hoist-pressure -fira-loop-pressure -fbranch-target-load-optimize -fweb -ftracer -fsched2-use-superblocks -fgraphite-identity -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -fno-plt -flto=2 -fuse-linker-plugin -fuse-ld=bfd -fstack-protector-all -fstack-clash-protection -Wall -Wextra -Wl,-O1 -Wl,--as-needed -Wl,-O3 -Wl,-z,relro -Wl,-z,now"

sandy@sandys-pavilion:~$ cat /etc/portage/package.cflags/dav1d.conf
media-libs/dav1d *FLAGS-="-floop-nest-optimize"

GRAPHITE="-fgraphite-identity -floop-nest-optimize"

~~~

@jiblime, it seems that the loops are out to get us. I will double-check after I rebuild @world for the holidays. Oh, also, ahemGitterahem.

Edit

I get the same result with Gold.

Edit two

Using my previous flags does not make a difference.

dav1d-0.5.2 also builds with gcc-8.3.0 successfully for me

reported to gentoo bugs as https://bugs.gentoo.org/702968
was on the fence as it might be an isl issue, but then I noticed dav1d and the scipy minimal testcase both compile successfully with gcc-8.3.0. I guess I'll see what the devs have to say.

Merged the test disabling patch -- will leave the issue open until this gets fixed properly upstream

Now... How might one actively avoid the patched package from this overlay for the purpose of actively checking on one's own system?

@elsandosgrande
Re-patch again w/ one more custom patch or use custom ebuild, where it should be something like

local emesonargs=(
...
-Denable_tests=true
...
)

This is how it might be fixed in gentoo, the patch was only for this overlay. For simplicity.

confirmed as an ISL regression. when 0.22.1 or 0.23 makes it into the tree, we'll be able to revert the flag filters for this and #450

EDIT: gentoo pulled a patch for this fix into 0.22-r1, which is curently available.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Althorion picture Althorion  Â·  10Comments

Hello71 picture Hello71  Â·  5Comments

ElDavoo picture ElDavoo  Â·  5Comments

mid-kid picture mid-kid  Â·  5Comments

Peter-Levine picture Peter-Levine  Â·  15Comments