Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

avx512 support regression in 1.43 #71473

Closed
lu-zero opened this issue Apr 23, 2020 · 13 comments · Fixed by #71495
Closed

avx512 support regression in 1.43 #71473

lu-zero opened this issue Apr 23, 2020 · 13 comments · Fixed by #71495
Labels
disposition-merge This issue / PR is in PFCP or FCP with a disposition to merge it. finished-final-comment-period The final comment period is finished for this PR / Issue. regression-from-stable-to-stable Performance or correctness regression from one stable version to another. T-libs-api Relevant to the library API team, which will review and decide on the PR/issue.

Comments

@lu-zero
Copy link
Contributor

lu-zero commented Apr 23, 2020

error[E0658]: use of unstable library feature 'stdsimd'
  --> src/cpu_features/x86.rs:50:12
   |
50 |         && is_x86_feature_detected!("avx512ifma")
   |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   |
   = note: see issue #27731 <https://github.com/rust-lang/rust/issues/27731> for more information
   = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)

It was notified on zulip before

lu-zero added a commit to rust-av/rav1e that referenced this issue Apr 23, 2020
Due some miscommunication upstream disabled all the icelake flags in the
current stable release.

The issue is tracked in rust-lang/rust#71473
lu-zero added a commit to rust-av/rav1e that referenced this issue Apr 23, 2020
Due some miscommunication upstream disabled all the icelake flags in the
current stable release.

The issue is tracked in rust-lang/rust#71473
@shssoichiro
Copy link
Contributor

Note that this worked in 1.42, so this is a stable-to-stable regression.

@Amanieu
Copy link
Member

Amanieu commented Apr 23, 2020

This basically #68905. We re-stabilized some of the avx512 features that were used by BLAKE3, but it seems that we missed rav1e.

@joshtriplett joshtriplett added I-nominated T-lang Relevant to the language team, which will review and decide on the PR/issue. labels Apr 23, 2020
@joshtriplett
Copy link
Member

@Amanieu Any chance you could prepare a fix? I think this is worth a stable point release.

lu-zero added a commit to rust-av/rav1e that referenced this issue Apr 23, 2020
Due some miscommunication upstream disabled all the icelake flags in the
current stable release.

The issue is tracked in rust-lang/rust#71473
lu-zero added a commit to rust-av/rav1e that referenced this issue Apr 23, 2020
Due some miscommunication upstream disabled all the icelake flags in the
current stable release.

The issue is tracked in rust-lang/rust#71473
@joshtriplett
Copy link
Member

Summarizing some discussions in the lang team meeting, regarding CPU feature naming: there are inconsistencies in feature naming between LLVM, GCC, GAS, and the Linux kernel, but we have a mild technical reason to defer to LLVM (doing otherwise requires renaming the feature). So let's defer to LLVM naming of CPU features, which doesn't tend to use underscores.

@joshtriplett joshtriplett added regression-from-stable-to-stable Performance or correctness regression from one stable version to another. stable-nominated Nominated for backporting to the compiler in the stable channel. labels Apr 23, 2020
@Amanieu Amanieu added T-libs-api Relevant to the library API team, which will review and decide on the PR/issue. and removed T-lang Relevant to the language team, which will review and decide on the PR/issue. labels Apr 23, 2020
@Amanieu
Copy link
Member

Amanieu commented Apr 23, 2020

In rust-lang/stdarch#849 I stabilized all remaining x86 features for feature detection.

@rfcbot fcp merge

@rfcbot
Copy link

rfcbot commented Apr 23, 2020

Team member @Amanieu has proposed to merge this. The next step is review by the rest of the tagged team members:

No concerns currently listed.

Once a majority of reviewers approve (and at most 2 approvals are outstanding), this will enter its final comment period. If you spot a major issue that hasn't been raised at any point in this process, please speak up!

See this document for info about what commands tagged team members can give me.

@rfcbot rfcbot added proposed-final-comment-period Proposed to merge/close by relevant subteam, see T-<team> label. Will enter FCP once signed off. disposition-merge This issue / PR is in PFCP or FCP with a disposition to merge it. labels Apr 23, 2020
@est31
Copy link
Member

est31 commented Apr 23, 2020

Why wasn't this caught by the crater runs for 1.43? It builds stuff from github, no?

@rfcbot rfcbot added final-comment-period In the final comment period and will be merged soon unless new substantive objections are raised. and removed proposed-final-comment-period Proposed to merge/close by relevant subteam, see T-<team> label. Will enter FCP once signed off. labels Apr 23, 2020
@rfcbot
Copy link

rfcbot commented Apr 23, 2020

🔔 This is now entering its final comment period, as per the review above. 🔔

@est31
Copy link
Member

est31 commented Apr 23, 2020

Hmm yeah there were issues compiling the asm files:

[INFO] [stderr] Caused by:
[INFO] [stderr]   process didn't exit successfully: `/opt/rustwide/target/debug/build/rav1e-3a89a641e64125d3/build-script-build` (exit code: 101)
[INFO] [stderr] --- stdout
[INFO] [stderr] cargo:rustc-cfg=nasm_x86_64
[INFO] [stderr] running: "nasm" "-felf64" "-gdwarf" "-I/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/" "-Isrc/" "/opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/ipred.asm" "-o" "/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/src/x86/ipred.o"
[INFO] [stderr] running: "nasm" "-felf64" "-gdwarf" "-I/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/" "-Isrc/" "/opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/me.asm" "-o" "/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/src/x86/me.o"
[INFO] [stderr] running: "nasm" "-felf64" "-gdwarf" "-I/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/" "-Isrc/" "/opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/itx_ssse3.asm" "-o" "/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/src/x86/itx_ssse3.o"
[INFO] [stderr] running: "nasm" "-felf64" "-gdwarf" "-I/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/" "-Isrc/" "/opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/ipred_ssse3.asm" "-o" "/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/src/x86/ipred_ssse3.o"
[INFO] [stderr] running: "nasm" "-felf64" "-gdwarf" "-I/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/" "-Isrc/" "/opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/satd.asm" "-o" "/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/src/x86/satd.o"
[INFO] [stderr] running: "nasm" "-felf64" "-gdwarf" "-I/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/" "-Isrc/" "/opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm" "-o" "/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/src/x86/mc.o"
[INFO] [stderr] running: "nasm" "-felf64" "-gdwarf" "-I/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/" "-Isrc/" "/opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/cdef.asm" "-o" "/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/src/x86/cdef.o"
[INFO] [stderr] running: "nasm" "-felf64" "-gdwarf" "-I/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/" "-Isrc/" "/opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/itx.asm" "-o" "/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/src/x86/itx.o"
[INFO] [stderr] running: "nasm" "-felf64" "-gdwarf" "-I/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/" "-Isrc/" "/opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/sad_sse2.asm" "-o" "/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/src/x86/sad_sse2.o"
[INFO] [stderr] running: "nasm" "-felf64" "-gdwarf" "-I/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/" "-Isrc/" "/opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/tables.asm" "-o" "/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/src/x86/tables.o"
[INFO] [stderr] running: "nasm" "-felf64" "-gdwarf" "-I/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/" "-Isrc/" "/opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc_ssse3.asm" "-o" "/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/src/x86/mc_ssse3.o"
[INFO] [stderr] running: "nasm" "-felf64" "-gdwarf" "-I/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/" "-Isrc/" "/opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/sad_avx.asm" "-o" "/opt/rustwide/target/debug/build/rav1e-05e9929c2949d6bf/out/src/x86/sad_avx.o"
[INFO] [stderr] 
[INFO] [stderr] --- stderr
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:5506: error: parser: instruction expected
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:2767: ... from macro `PREP_8TAP' defined here
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:5506: error: symbol `vpdpbusd' redefined
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:2768: ... from macro `PREP_8TAP' defined here
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:5506: error: parser: instruction expected
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:2768: ... from macro `PREP_8TAP' defined here
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:5506: error: symbol `vpdpbusd' redefined
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:2812: ... from macro `PREP_8TAP' defined here
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:5506: error: parser: instruction expected
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:2812: ... from macro `PREP_8TAP' defined here
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:5506: error: symbol `vpdpbusd' redefined
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:2813: ... from macro `PREP_8TAP' defined here
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:5506: error: parser: instruction expected
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:2813: ... from macro `PREP_8TAP' defined here
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:5506: error: symbol `vpdpbusd' redefined
[...]
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:4417: ... from macro `W_MASK' defined here
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:6009: error: symbol `vpshldw' redefined
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:4417: ... from macro `W_MASK' defined here
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:6009: error: parser: instruction expected
[INFO] [stderr] /opt/rustwide/cargo-home/git/checkouts/rav1e-14e16d25dd5cd9c0/91658bd/src/x86/mc.asm:4417: ... from macro `W_MASK' defined here
[INFO] [stderr] thread '<unnamed>' panicked at 'nonzero exit status: exit code: 1', /opt/rustwide/cargo-home/registry/src/github.com-1ecc6299db9ec823/nasm-rs-0.1.7/src/lib.rs:343:9

@Amanieu
Copy link
Member

Amanieu commented Apr 23, 2020

I looks like the assembler is too old and doesn't recognize the AVX-512 instructions

@Amanieu
Copy link
Member

Amanieu commented Apr 23, 2020

cc @rust-lang/infra We missed a regression on crater because it had an old version of nasm, which caused the rav1e crate to fail to compile. It seems that nasm 2.14 is required for the AVX512 instruction used.

@est31
Copy link
Member

est31 commented Apr 23, 2020

I looks like the assembler is too old and doesn't recognize the AVX-512 instructions

Hmm yeah that might be it. It seems to run Ubuntu 18.04 LTS which uses nasm 2.13. An update to 20.04 LTS will bring nasm 2.14 and probably fix the issue short term but not long term once rav1e starts requiring newer nasm versions.

@kennytm kennytm added the T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. label Apr 24, 2020
lu-zero added a commit to xiph/rav1e that referenced this issue Apr 24, 2020
Due some miscommunication upstream disabled all the icelake flags in the
current stable release.

The issue is tracked in rust-lang/rust#71473
shssoichiro pushed a commit to xiph/rav1e that referenced this issue Apr 24, 2020
In order to find regressions like
rust-lang/rust#71473
before stable releases.
@bors bors closed this as completed in ec1f28f Apr 26, 2020
@kennytm kennytm removed the T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. label Apr 29, 2020
@pnkfelix
Copy link
Member

pnkfelix commented May 1, 2020

(removing stable-nominated tag, as we nominate PR's for backport, not issues)

@pnkfelix pnkfelix removed the stable-nominated Nominated for backporting to the compiler in the stable channel. label May 1, 2020
@rfcbot rfcbot added finished-final-comment-period The final comment period is finished for this PR / Issue. and removed final-comment-period In the final comment period and will be merged soon unless new substantive objections are raised. labels May 3, 2020
bors added a commit to rust-lang-ci/rust that referenced this issue May 4, 2020
…roalbini

[stable] 1.43.1 release

* [Updated openssl-src to 1.1.1g for CVE-2020-1967.][71430]
* [Fixed the stabilization of AVX-512 features.][71473]
* [Fixed `cargo package --list` not working with unpublished dependencies.][cargo/8151]

[71430]: rust-lang#71430
[71473]: rust-lang#71473
[cargo/8151]: rust-lang/cargo#8151
netbsd-srcmastr pushed a commit to NetBSD/pkgsrc that referenced this issue May 17, 2020
Pkgsrc changes:
 * None.

Upstream changes:

Version 1.43.1 (2020-05-07)
===========================

* [Updated openssl-src to 1.1.1g for CVE-2020-1967.][71430]
* [Fixed the stabilization of AVX-512 features.][71473]
* [Fixed `cargo package --list` not working with unpublished dependencies.]
  [cargo/8151]

[71430]: rust-lang/rust#71430
[71473]: rust-lang/rust#71473
[cargo/8151]: rust-lang/cargo#8151
barrbrain pushed a commit to barrbrain/rav1e that referenced this issue May 26, 2020
In order to find regressions like
rust-lang/rust#71473
before stable releases.
barrbrain pushed a commit to xiph/rav1e that referenced this issue May 26, 2020
In order to find regressions like
rust-lang/rust#71473
before stable releases.
barrbrain pushed a commit to barrbrain/rav1e that referenced this issue May 26, 2020
Due some miscommunication upstream disabled all the icelake flags in the
current stable release.

The issue is tracked in rust-lang/rust#71473
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
disposition-merge This issue / PR is in PFCP or FCP with a disposition to merge it. finished-final-comment-period The final comment period is finished for this PR / Issue. regression-from-stable-to-stable Performance or correctness regression from one stable version to another. T-libs-api Relevant to the library API team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

8 participants