about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorPatrick Walton <pcwalton@mimiga.net>2012-09-11 12:12:13 -0700
committerPatrick Walton <pcwalton@mimiga.net>2012-09-11 12:12:13 -0700
commit23880daef2fbdfc01f8651fa8e84eb9700cceb3c (patch)
tree3f33d4801b62887b341ed690da9d6306e07e59f6 /src
parentcd8ec6d9236867d3f088432033f56b6ad29c15a7 (diff)
downloadrust-23880daef2fbdfc01f8651fa8e84eb9700cceb3c.tar.gz
rust-23880daef2fbdfc01f8651fa8e84eb9700cceb3c.zip
rustc: Remove the cmp type upcall
Diffstat (limited to 'src')
-rw-r--r--src/rustc/back/abi.rs6
-rw-r--r--src/rustc/back/upcall.rs7
-rw-r--r--src/rustc/middle/trans/glue.rs21
3 files changed, 0 insertions, 34 deletions
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;