X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=compiler%2Frustc_codegen_cranelift%2Fexample%2Fmini_core_hello_world.rs;h=d997ce6d1b379044fd3675420e9837739ef0aa10;hb=d531f3d6eef9eef1a699b3ffb6dce4e911690dca;hp=6570f2bf9f297fbccf66a4681d639a91f266a18f;hpb=7835c7802d7473c961e9d9d91467286a7f437948;p=rust.git diff --git a/compiler/rustc_codegen_cranelift/example/mini_core_hello_world.rs b/compiler/rustc_codegen_cranelift/example/mini_core_hello_world.rs index 6570f2bf9f2..d997ce6d1b3 100644 --- a/compiler/rustc_codegen_cranelift/example/mini_core_hello_world.rs +++ b/compiler/rustc_codegen_cranelift/example/mini_core_hello_world.rs @@ -292,7 +292,7 @@ struct ExternTypeWrapper { #[cfg(not(any(jit, windows)))] test_tls(); - #[cfg(all(not(jit), target_os = "linux"))] + #[cfg(all(not(jit), target_arch = "x86_64", target_os = "linux"))] unsafe { global_asm_test(); } @@ -303,12 +303,12 @@ struct ExternTypeWrapper { assert_eq!(*REF1, *REF2); } -#[cfg(all(not(jit), target_os = "linux"))] +#[cfg(all(not(jit), target_arch = "x86_64", target_os = "linux"))] extern "C" { fn global_asm_test(); } -#[cfg(all(not(jit), target_os = "linux"))] +#[cfg(all(not(jit), target_arch = "x86_64", target_os = "linux"))] global_asm! { " .global global_asm_test