Skip to content

Commit 12c19a2

Browse files
committed
target: fix powerpc64-unknown-linux-musl datalayout
In LLVM 17, PowerPC targets started including function pointer alignments in data layouts, and in Rust's update to that version (rust-lang#114048), we added the function pointer alignments. `powerpc64-unknown-linux-musl` had `Fi64` set but this seems incorrect, and the code in LLVM would always have computed `Fn32` because it is a MUSL target. Signed-off-by: David Wood <david@davidtw.co>
1 parent a87034c commit 12c19a2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/rustc_target/src/spec/targets/powerpc64_unknown_linux_musl.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ pub fn target() -> Target {
1111
Target {
1212
llvm_target: "powerpc64-unknown-linux-musl".into(),
1313
pointer_width: 64,
14-
data_layout: "E-m:e-Fi64-i64:64-n32:64-S128-v256:256:256-v512:512:512".into(),
14+
data_layout: "E-m:e-Fn32-i64:64-n32:64-S128-v256:256:256-v512:512:512".into(),
1515
arch: "powerpc64".into(),
1616
options: TargetOptions { endian: Endian::Big, mcount: "_mcount".into(), ..base },
1717
}

0 commit comments

Comments
 (0)