Skip to content

ICE when using ADX intrinsics on nightly #58020

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

Closed
jethrogb opened this issue Jan 31, 2019 · 4 comments
Closed

ICE when using ADX intrinsics on nightly #58020

jethrogb opened this issue Jan 31, 2019 · 4 comments
Labels
C-bug Category: This is a bug. 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) ❄️ T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@jethrogb
Copy link
Contributor

jethrogb commented Jan 31, 2019

unsafe fn add_1_2_3() -> u32{
    let mut out = 0;
    std::arch::x86_64::_addcarryx_u32(1, 2, 3, &mut out);
    out
}

fn main() {
    if is_x86_feature_detected!("adx") {
        println!("{}", unsafe { add_1_2_3() });
    }
}
$ rustc +nightly --version
rustc 1.34.0-nightly (d8a0dd7ae 2019-01-28)
$ rustc +nightly adx.rs
Invalid bitcast
i32* bitcast (void <badref> to i32*)
Referencing global in another module!
i32* bitcast (void <badref> to i32*)
; ModuleID = 'feat.7rcbfp3g-cgu.2'
void <badref>
; ModuleID = 'Segmentation fault (core dumped)

Regression from beta to nightly

@jethrogb jethrogb changed the title ICE when using ADX feature ICE when using ADX intrinsics Jan 31, 2019
@jethrogb jethrogb changed the title ICE when using ADX intrinsics ICE when using ADX intrinsics on nightly Jan 31, 2019
@jethrogb
Copy link
Contributor Author

This might be #57993 / rust-lang/stdarch#661

@Centril Centril added the I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ label Jan 31, 2019
@jonas-schievink jonas-schievink added the E-needs-test Call for participation: An issue has been fixed and does not reproduce, but no test has been added. label Apr 16, 2019
@jonas-schievink
Copy link
Contributor

No longer reproduces, marking as needstest.

@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 Apr 16, 2019
@gnzlbg
Copy link
Contributor

gnzlbg commented Apr 19, 2019

We have added a test for this in stdsimd.

@jonas-schievink
Copy link
Contributor

Great! In that case, closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: This is a bug. 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) ❄️ 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

4 participants