|
10 | 10 |
|
11 | 11 | #[allow(non_uppercase_pattern_statics)];
|
12 | 12 |
|
13 |
| -use back::{abi}; |
| 13 | +use back::abi; |
14 | 14 | use lib::llvm::{SequentiallyConsistent, Acquire, Release, Xchg};
|
15 | 15 | use lib::llvm::{ValueRef, Pointer, Array, Struct};
|
16 | 16 | use lib;
|
17 | 17 | use middle::trans::base::*;
|
18 | 18 | use middle::trans::build::*;
|
19 |
| -use middle::trans::callee::*; |
20 | 19 | use middle::trans::common::*;
|
21 | 20 | use middle::trans::datum::*;
|
22 | 21 | use middle::trans::type_of::*;
|
23 | 22 | use middle::trans::type_of;
|
24 |
| -use middle::trans::expr::Ignore; |
25 | 23 | use middle::trans::machine;
|
26 | 24 | use middle::trans::glue;
|
27 |
| -use middle::ty::FnSig; |
28 | 25 | use middle::ty;
|
29 | 26 | use syntax::ast;
|
30 | 27 | use syntax::ast_map;
|
31 | 28 | use syntax::attr;
|
32 |
| -use syntax::opt_vec; |
33 |
| -use util::ppaux::{ty_to_str}; |
| 29 | +use util::ppaux::ty_to_str; |
34 | 30 | use middle::trans::machine::llsize_of;
|
35 | 31 | use middle::trans::type_::Type;
|
36 | 32 |
|
@@ -387,33 +383,6 @@ pub fn trans_intrinsic(ccx: @mut CrateContext,
|
387 | 383 | abi::tydesc_field_visit_glue, None);
|
388 | 384 | RetVoid(bcx);
|
389 | 385 | }
|
390 |
| - "frame_address" => { |
391 |
| - let frameaddress = ccx.intrinsics.get_copy(& &"llvm.frameaddress"); |
392 |
| - let frameaddress_val = Call(bcx, frameaddress, [C_i32(0i32)], []); |
393 |
| - let star_u8 = ty::mk_imm_ptr( |
394 |
| - bcx.tcx(), |
395 |
| - ty::mk_mach_uint(ast::ty_u8)); |
396 |
| - let fty = ty::mk_closure(bcx.tcx(), ty::ClosureTy { |
397 |
| - purity: ast::impure_fn, |
398 |
| - sigil: ast::BorrowedSigil, |
399 |
| - onceness: ast::Many, |
400 |
| - region: ty::re_bound(ty::br_anon(0)), |
401 |
| - bounds: ty::EmptyBuiltinBounds(), |
402 |
| - sig: FnSig { |
403 |
| - bound_lifetime_names: opt_vec::Empty, |
404 |
| - inputs: ~[ star_u8 ], |
405 |
| - output: ty::mk_nil() |
406 |
| - } |
407 |
| - }); |
408 |
| - let datum = Datum {val: get_param(decl, first_real_arg), |
409 |
| - mode: ByRef(ZeroMem), ty: fty}; |
410 |
| - let arg_vals = ~[frameaddress_val]; |
411 |
| - bcx = trans_call_inner( |
412 |
| - bcx, None, fty, ty::mk_nil(), |
413 |
| - |bcx| Callee {bcx: bcx, data: Closure(datum)}, |
414 |
| - ArgVals(arg_vals), Some(Ignore), DontAutorefArg).bcx; |
415 |
| - RetVoid(bcx); |
416 |
| - } |
417 | 386 | "morestack_addr" => {
|
418 | 387 | // XXX This is a hack to grab the address of this particular
|
419 | 388 | // native function. There should be a general in-language
|
|
0 commit comments