diff --git a/src/rustc/back/abi.rs b/src/rustc/back/abi.rs index 706c8ed991e..7c35e3d892d 100644 --- a/src/rustc/back/abi.rs +++ b/src/rustc/back/abi.rs @@ -43,12 +43,6 @@ const tydesc_field_shape: uint = 6u; const tydesc_field_shape_tables: uint = 7u; const n_tydesc_fields: uint = 8u; -const cmp_glue_op_eq: uint = 0u; - -const cmp_glue_op_lt: uint = 1u; - -const cmp_glue_op_le: uint = 2u; - // The two halves of a closure: code and environment. const fn_field_code: uint = 0u; const fn_field_box: uint = 1u; diff --git a/src/rustc/back/upcall.rs b/src/rustc/back/upcall.rs index 8f6e48574b5..66241c7aa6d 100644 --- a/src/rustc/back/upcall.rs +++ b/src/rustc/back/upcall.rs @@ -18,7 +18,6 @@ type upcalls = mark: ValueRef, str_new_uniq: ValueRef, str_new_shared: ValueRef, - cmp_type: ValueRef, log_type: ValueRef, call_shim_on_c_stack: ValueRef, call_shim_on_rust_stack: ValueRef, @@ -74,12 +73,6 @@ fn declare_upcalls(targ_cfg: @session::config, str_new_shared: nothrow(d(~"str_new_shared", ~[T_ptr(T_i8()), int_t], T_ptr(T_i8()))), - cmp_type: - dv(~"cmp_type", - ~[T_ptr(T_i1()), T_ptr(tydesc_type), - T_ptr(T_i8()), - T_ptr(T_i8()), - T_i8()]), log_type: dv(~"log_type", ~[T_ptr(tydesc_type), T_ptr(T_i8()), T_i32()]), diff --git a/src/rustc/middle/trans/glue.rs b/src/rustc/middle/trans/glue.rs index 3aee04755f0..384f6e71198 100644 --- a/src/rustc/middle/trans/glue.rs +++ b/src/rustc/middle/trans/glue.rs @@ -253,27 +253,6 @@ fn call_tydesc_glue(++cx: block, v: ValueRef, t: ty::t, field: uint) return cx; } -fn call_cmp_glue(bcx: block, lhs: ValueRef, rhs: ValueRef, t: ty::t, - llop: ValueRef) -> ValueRef { - // We can't use call_tydesc_glue_full() and friends here because compare - // glue has a special signature. - let _icx = bcx.insn_ctxt("call_cmp_glue"); - - let lllhs = spill_if_immediate(bcx, lhs, t); - let llrhs = spill_if_immediate(bcx, rhs, t); - - let llrawlhsptr = BitCast(bcx, lllhs, T_ptr(T_i8())); - let llrawrhsptr = BitCast(bcx, llrhs, T_ptr(T_i8())); - let lltydesc = get_tydesc_simple(bcx.ccx(), t); - - let llfn = bcx.ccx().upcalls.cmp_type; - - let llcmpresultptr = alloca(bcx, T_i1()); - Call(bcx, llfn, ~[llcmpresultptr, lltydesc, - llrawlhsptr, llrawrhsptr, llop]); - return Load(bcx, llcmpresultptr); -} - fn make_visit_glue(bcx: block, v: ValueRef, t: ty::t) { let _icx = bcx.insn_ctxt("make_visit_glue"); let mut bcx = bcx;