Skip to content

Commit c8442af

Browse files
committed
powerpc: Add backend support for powerpc
1 parent e5bbe82 commit c8442af

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

src/libcoretest/mem.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@ fn size_of_basic() {
2222
#[cfg(any(target_arch = "x86",
2323
target_arch = "arm",
2424
target_arch = "mips",
25-
target_arch = "mipsel"))]
25+
target_arch = "mipsel",
26+
target_arch = "powerpc"))]
2627
fn size_of_32() {
2728
assert_eq!(size_of::<uint>(), 4u);
2829
assert_eq!(size_of::<*const uint>(), 4u);
@@ -55,7 +56,8 @@ fn align_of_basic() {
5556
#[cfg(any(target_arch = "x86",
5657
target_arch = "arm",
5758
target_arch = "mips",
58-
target_arch = "mipsel"))]
59+
target_arch = "mipsel",
60+
target_arch = "powerpc"))]
5961
fn align_of_32() {
6062
assert_eq!(align_of::<uint>(), 4u);
6163
assert_eq!(align_of::<*const uint>(), 4u);

src/librustc_back/target/mod.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ mod i686_unknown_dragonfly;
7272
mod i686_unknown_linux_gnu;
7373
mod mips_unknown_linux_gnu;
7474
mod mipsel_unknown_linux_gnu;
75+
mod powerpc_unknown_linux_gnu;
7576
mod x86_64_apple_darwin;
7677
mod x86_64_apple_ios;
7778
mod x86_64_pc_windows_gnu;
@@ -95,7 +96,7 @@ pub struct Target {
9596
/// OS name to use for conditional compilation.
9697
pub target_os: String,
9798
/// Architecture to use for ABI considerations. Valid options: "x86", "x86_64", "arm",
98-
/// "aarch64", and "mips". "mips" includes "mipsel".
99+
/// "aarch64", "mips", and "powerpc". "mips" includes "mipsel".
99100
pub arch: String,
100101
/// Optional settings with defaults.
101102
pub options: TargetOptions,
@@ -339,6 +340,7 @@ impl Target {
339340
i686_unknown_linux_gnu,
340341
mips_unknown_linux_gnu,
341342
mipsel_unknown_linux_gnu,
343+
powerpc_unknown_linux_gnu,
342344
arm_linux_androideabi,
343345
arm_unknown_linux_gnueabi,
344346
arm_unknown_linux_gnueabihf,

0 commit comments

Comments
 (0)