Skip to content

Commit

Permalink
target: fix powerpc64-unknown-linux-musl datalayout
Browse files Browse the repository at this point in the history
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 <[email protected]>
  • Loading branch information
davidtwco committed Jan 17, 2024
1 parent a87034c commit 12c19a2
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ pub fn target() -> Target {
Target {
llvm_target: "powerpc64-unknown-linux-musl".into(),
pointer_width: 64,
data_layout: "E-m:e-Fi64-i64:64-n32:64-S128-v256:256:256-v512:512:512".into(),
data_layout: "E-m:e-Fn32-i64:64-n32:64-S128-v256:256:256-v512:512:512".into(),
arch: "powerpc64".into(),
options: TargetOptions { endian: Endian::Big, mcount: "_mcount".into(), ..base },
}
Expand Down

0 comments on commit 12c19a2

Please sign in to comment.