Skip to content

Commit 8eb0ef0

Browse files
committed
---
yaml --- r: 174003 b: refs/heads/batch c: 33cd9cf h: refs/heads/master i: 174001: ce6a340 173999: df24d74 v: v3
1 parent 9d48f5d commit 8eb0ef0

File tree

4 files changed

+44
-1
lines changed

4 files changed

+44
-1
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ refs/tags/0.12.0: f0c419429ef30723ceaf6b42f9b5a2aeb5d2e2d1
2929
refs/heads/issue-18208-method-dispatch-2: 9e1eae4fb9b6527315b4441cf8a0f5ca911d1671
3030
refs/heads/automation-fail: 1bf06495443584539b958873e04cc2f864ab10e4
3131
refs/heads/issue-18208-method-dispatch-3-quick-reject: 2009f85b9f99dedcec4404418eda9ddba90258a2
32-
refs/heads/batch: c8442afeb066656c4f4db3ca8538ee5976b504f6
32+
refs/heads/batch: 33cd9cf9f463b6eb6153d0698ca8d209ab95efec
3333
refs/heads/building: 126db549b038c84269a1e4fe46f051b2c15d6970
3434
refs/heads/beta: 44a287e6eb22ec3c2a687fc156813577464017f7
3535
refs/heads/windistfix: 7608dbad651f02e837ed05eef3d74a6662a6e928
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
2+
// file at the top-level directory of this distribution and at
3+
// http://rust-lang.org/COPYRIGHT.
4+
//
5+
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
6+
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
7+
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
8+
// option. This file may not be copied, modified, or distributed
9+
// except according to those terms.
10+
11+
use target::Target;
12+
13+
pub fn target() -> Target {
14+
let mut base = super::linux_base::opts();
15+
base.pre_link_args.push("-m32".to_string());
16+
17+
Target {
18+
data_layout: "E-S8-p:32:32-f64:32:64-i64:32:64-f80:32:32-n8:16:32".to_string(),
19+
llvm_target: "powerpc-unknown-linux-gnu".to_string(),
20+
target_endian: "big".to_string(),
21+
target_word_size: "32".to_string(),
22+
arch: "powerpc".to_string(),
23+
target_os: "linux".to_string(),
24+
options: base,
25+
}
26+
}

branches/batch/src/librustc_llvm/lib.rs

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1974,6 +1974,11 @@ extern {
19741974
pub fn LLVMInitializeMipsTargetMC();
19751975
pub fn LLVMInitializeMipsAsmPrinter();
19761976
pub fn LLVMInitializeMipsAsmParser();
1977+
pub fn LLVMInitializePowerPCTargetInfo();
1978+
pub fn LLVMInitializePowerPCTarget();
1979+
pub fn LLVMInitializePowerPCTargetMC();
1980+
pub fn LLVMInitializePowerPCAsmPrinter();
1981+
pub fn LLVMInitializePowerPCAsmParser();
19771982

19781983
pub fn LLVMRustAddPass(PM: PassManagerRef, Pass: *const c_char) -> bool;
19791984
pub fn LLVMRustCreateTargetMachine(Triple: *const c_char,
@@ -2249,6 +2254,12 @@ pub unsafe fn static_link_hack_this_sucks() {
22492254
LLVMInitializeMipsAsmPrinter();
22502255
LLVMInitializeMipsAsmParser();
22512256

2257+
LLVMInitializePowerPCTargetInfo();
2258+
LLVMInitializePowerPCTarget();
2259+
LLVMInitializePowerPCTargetMC();
2260+
LLVMInitializePowerPCAsmPrinter();
2261+
LLVMInitializePowerPCAsmParser();
2262+
22522263
LLVMRustSetLLVMOptions(0 as c_int,
22532264
0 as *const _);
22542265

branches/batch/src/librustc_trans/back/write.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1039,6 +1039,12 @@ unsafe fn configure_llvm(sess: &Session) {
10391039
llvm::LLVMInitializeMipsAsmPrinter();
10401040
llvm::LLVMInitializeMipsAsmParser();
10411041

1042+
llvm::LLVMInitializePowerPCTargetInfo();
1043+
llvm::LLVMInitializePowerPCTarget();
1044+
llvm::LLVMInitializePowerPCTargetMC();
1045+
llvm::LLVMInitializePowerPCAsmPrinter();
1046+
llvm::LLVMInitializePowerPCAsmParser();
1047+
10421048
llvm::LLVMRustSetLLVMOptions(llvm_args.len() as c_int,
10431049
llvm_args.as_ptr());
10441050
});

0 commit comments

Comments
 (0)