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

LLVM ERROR: Cannot select: 0xffff6c0e10d8: i32 = vecreduce_mul 0xffff6c072990 #54510

Closed
parched opened this issue Sep 23, 2018 · 9 comments
Closed
Labels
A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. C-bug Category: This is a bug. E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. E-mentor Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion. E-needs-test Call for participation: An issue has been fixed and does not reproduce, but no test has been added. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ O-Arm Target: 32-bit Arm processors (armv6, armv7, thumb...), including 64-bit Arm in AArch32 state T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@parched
Copy link
Contributor

parched commented Sep 23, 2018

Running x.py test --stage 1 on aarch64-unknown-linux-gnu I get one failed test as shown below. This is the first time I've run the tests on this target some I'm unsure if it's a regression.
Nightly commit af50e38

CC @gnzlbg ?

---- [ui] ui/run-pass/simd/simd-intrinsic-generic-reduction.rs stdout ----                                                
                                                                                                                          
error: test compilation failed although it shouldn't!                                                                     
status: exit code: 1                                                                                                      
command: "/usr/src/myapp/build/aarch64-unknown-linux-gnu/stage1/bin/rustc" "/usr/src/myapp/src/test/ui/run-pass/simd/simd-
intrinsic-generic-reduction.rs" "--target=aarch64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-d
ynamic" "-o" "/usr/src/myapp/build/aarch64-unknown-linux-gnu/test/ui/run-pass/simd/simd-intrinsic-generic-reduction/a" "-C
rpath" "-O" "-Zunstable-options" "-Lnative=/usr/src/myapp/build/aarch64-unknown-linux-gnu/native/rust-test-helpers" "-L" "
/usr/src/myapp/build/aarch64-unknown-linux-gnu/test/ui/run-pass/simd/simd-intrinsic-generic-reduction/auxiliary" "-A" "unu
sed"                                                                                                                      
stdout:                                                                                                                   
------------------------------------------                                                                                
                                                                                                                          
------------------------------------------                                                                                
stderr:                                                                                                                   
------------------------------------------                                                                                
LLVM ERROR: Cannot select: 0xffff6c0e10d8: i32 = vecreduce_mul 0xffff6c072990                                             
  0xffff6c072990: v4i32,ch = load<(load 16 from constant-pool)> 0xffff6c0c6eb8, 0xffff6c0e1620, undef:i64                 
    0xffff6c0e1620: i64 = AArch64ISD::ADDlow 0xffff6c0727f0, TargetConstantPool:i64<<4 x i32> <i32 1, i32 -2, i32 3, i32 4
>> 0 [TF=34]                                                                                                              
      0xffff6c0727f0: i64 = AArch64ISD::ADRP TargetConstantPool:i64<<4 x i32> <i32 1, i32 -2, i32 3, i32 4>> 0 [TF=1]     
        0xffff6c0728c0: i64 = TargetConstantPool<<4 x i32> <i32 1, i32 -2, i32 3, i32 4>> 0 [TF=1]                        
      0xffff6c0726b8: i64 = TargetConstantPool<<4 x i32> <i32 1, i32 -2, i32 3, i32 4>> 0 [TF=34]                         
    0xffff6c0e1008: i64 = undef                                                                                           
In function: _ZN32simd_intrinsic_generic_reduction4main17h19818a8328796d6fE                                               
                                                                                                                          
------------------------------------------                                                                                
                                                                                                                          
thread '[ui] ui/run-pass/simd/simd-intrinsic-generic-reduction.rs' panicked at 'explicit panic', tools/compiletest/src/run
test.rs:3238:9
@gnzlbg
Copy link
Contributor

gnzlbg commented Sep 23, 2018

I think that's some flavor of https://bugs.llvm.org/show_bug.cgi?id=36796.

On stdsimd/packed_simd we work around this by falling back to scalar code instead, so this shouldn't be used anywhere in the ecosystem on aarch64 anyways.

The "fix" for this is to just ignore this test on aarch64.

@nagisa nagisa added A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ O-Arm Target: 32-bit Arm processors (armv6, armv7, thumb...), including 64-bit Arm in AArch32 state labels Sep 24, 2018
parched pushed a commit to parched/rust that referenced this issue Jan 22, 2019
Centril added a commit to Centril/rust that referenced this issue Jan 26, 2019
Ignore aarch64 in simd-intrinsic-generic-reduction

This fails on AArch64 see rust-lang#54510

Disabling it for now until it's fixed/implemented in LLVM

cc @gnzlbg
Centril added a commit to Centril/rust that referenced this issue Jan 26, 2019
Ignore aarch64 in simd-intrinsic-generic-reduction

This fails on AArch64 see rust-lang#54510

Disabling it for now until it's fixed/implemented in LLVM

cc @gnzlbg
Centril added a commit to Centril/rust that referenced this issue Jan 26, 2019
Ignore aarch64 in simd-intrinsic-generic-reduction

This fails on AArch64 see rust-lang#54510

Disabling it for now until it's fixed/implemented in LLVM

cc @gnzlbg
@sanxiyn
Copy link
Member

sanxiyn commented Mar 19, 2019

Update: LLVM PR36796 is fixed.

@mati865
Copy link
Contributor

mati865 commented Mar 19, 2019

It's not merged to Rust's LLVM fork.

@jonas-schievink jonas-schievink added C-bug Category: This is a bug. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Aug 6, 2019
@Centril
Copy link
Contributor

Centril commented Mar 10, 2020

@sanxiyn @mati865 How about now?

@hanna-kruppe
Copy link
Contributor

FWIW the commit was released in LLVM 9 which rustc currently uses, so this ought to be fixed.

@Centril Centril added the E-needs-test Call for participation: An issue has been fixed and does not reproduce, but no test has been added. label Mar 10, 2020
@Centril
Copy link
Contributor

Centril commented Mar 10, 2020

Seems like we need to add a test in that case.

@hanna-kruppe
Copy link
Contributor

No need for a new test, reverting #57827 (not ignoring that test on AArch64 any longer) should suffice. Although I'm not sure if we have CI for that target.

@Centril Centril added E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. E-mentor Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion. labels Mar 10, 2020
@nikic
Copy link
Contributor

nikic commented Mar 10, 2020

I'd suggest to wait for the LLVM 10 upgrade, which will address some additional issues. While LLVM 9 fixed the majority of this, there were still issues with ordered and non-fast reductions in some cases.

@JohnTitor
Copy link
Member

Triage: #57827 is already "reverted" in 6fae7db#diff-1910500d7497a3476e28b7c81e4954faR5 and we're on LLVM 10 now. I think there's nothing more we could do here? Closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. C-bug Category: This is a bug. E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. E-mentor Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion. E-needs-test Call for participation: An issue has been fixed and does not reproduce, but no test has been added. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ O-Arm Target: 32-bit Arm processors (armv6, armv7, thumb...), including 64-bit Arm in AArch32 state T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

10 participants