about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/rustc/middle/trans/foreign.rs20
-rw-r--r--src/rustc/middle/trans/type_use.rs10
-rw-r--r--src/rustc/middle/typeck/check.rs10
3 files changed, 11 insertions, 29 deletions
diff --git a/src/rustc/middle/trans/foreign.rs b/src/rustc/middle/trans/foreign.rs
index d5255bd1713..10e657af0f4 100644
--- a/src/rustc/middle/trans/foreign.rs
+++ b/src/rustc/middle/trans/foreign.rs
@@ -800,65 +800,63 @@ fn trans_intrinsic(ccx: @crate_ctxt, decl: ValueRef, item: @ast::foreign_item,
                                some(substs), some(item.span));
     let mut bcx = top_scope_block(fcx, none), lltop = bcx.llbb;
     match ccx.sess.str_of(item.ident) {
-      // NB: Transitionary, de-mode-ing. Remove the first string of each
-      // pattern when the old intrinsics are gone.
-      ~"atomic_xchng" | ~"atomic_xchg" => {
+      ~"atomic_xchg" => {
         let old = AtomicRMW(bcx, Xchg,
                   get_param(decl, first_real_arg),
                   get_param(decl, first_real_arg + 1u),
                   SequentiallyConsistent);
         Store(bcx, old, fcx.llretptr);
       }
-      ~"atomic_xchng_acq" | ~"atomic_xchg_acq" => {
+      ~"atomic_xchg_acq" => {
         let old = AtomicRMW(bcx, Xchg,
                   get_param(decl, first_real_arg),
                   get_param(decl, first_real_arg + 1u),
                   Acquire);
         Store(bcx, old, fcx.llretptr);
       }
-      ~"atomic_xchng_rel" | ~"atomic_xchg_rel" => {
+      ~"atomic_xchg_rel" => {
         let old = AtomicRMW(bcx, Xchg,
                   get_param(decl, first_real_arg),
                   get_param(decl, first_real_arg + 1u),
                   Release);
         Store(bcx, old, fcx.llretptr);
       }
-      ~"atomic_add" | ~"atomic_xadd" => {
+      ~"atomic_xadd" => {
         let old = AtomicRMW(bcx, lib::llvm::Add,
                   get_param(decl, first_real_arg),
                   get_param(decl, first_real_arg + 1u),
                   SequentiallyConsistent);
         Store(bcx, old, fcx.llretptr);
       }
-      ~"atomic_add_acq" | ~"atomic_xadd_acq" => {
+      ~"atomic_xadd_acq" => {
         let old = AtomicRMW(bcx, lib::llvm::Add,
                   get_param(decl, first_real_arg),
                   get_param(decl, first_real_arg + 1u),
                   Acquire);
         Store(bcx, old, fcx.llretptr);
       }
-      ~"atomic_add_rel" | ~"atomic_xadd_rel" => {
+      ~"atomic_xadd_rel" => {
         let old = AtomicRMW(bcx, lib::llvm::Add,
                   get_param(decl, first_real_arg),
                   get_param(decl, first_real_arg + 1u),
                   Release);
         Store(bcx, old, fcx.llretptr);
       }
-      ~"atomic_sub" | ~"atomic_xsub" => {
+      ~"atomic_xsub" => {
         let old = AtomicRMW(bcx, lib::llvm::Sub,
                   get_param(decl, first_real_arg),
                   get_param(decl, first_real_arg + 1u),
                   SequentiallyConsistent);
         Store(bcx, old, fcx.llretptr);
       }
-      ~"atomic_sub_acq" | ~"atomic_xsub_acq" => {
+      ~"atomic_xsub_acq" => {
         let old = AtomicRMW(bcx, lib::llvm::Sub,
                   get_param(decl, first_real_arg),
                   get_param(decl, first_real_arg + 1u),
                   Acquire);
         Store(bcx, old, fcx.llretptr);
       }
-      ~"atomic_sub_rel" | ~"atomic_xsub_rel" => {
+      ~"atomic_xsub_rel" => {
         let old = AtomicRMW(bcx, lib::llvm::Sub,
                   get_param(decl, first_real_arg),
                   get_param(decl, first_real_arg + 1u),
diff --git a/src/rustc/middle/trans/type_use.rs b/src/rustc/middle/trans/type_use.rs
index 1b084670f94..004de82e064 100644
--- a/src/rustc/middle/trans/type_use.rs
+++ b/src/rustc/middle/trans/type_use.rs
@@ -90,16 +90,10 @@ fn type_uses_for(ccx: @crate_ctxt, fn_id: def_id, n_tps: uint)
               ~"get_tydesc" | ~"needs_drop" => {
                 use_tydesc
               }
-              // NB: new intrinsics
               ~"atomic_xchg"     | ~"atomic_xadd"     | ~"atomic_xsub" |
               ~"atomic_xchg_acq" | ~"atomic_xadd_acq" | ~"atomic_xsub_acq" |
-              ~"atomic_xchg_rel" | ~"atomic_xadd_rel" | ~"atomic_xsub_rel" |
-              // old intrinsics
-              ~"atomic_xchng" | ~"atomic_add" | ~"atomic_sub" |
-              ~"atomic_xchng_acq" | ~"atomic_add_acq" | ~"atomic_sub_acq" |
-              ~"atomic_xchng_rel" | ~"atomic_add_rel" | ~"atomic_sub_rel" => {
-                0u
-              }
+              ~"atomic_xchg_rel" | ~"atomic_xadd_rel" | ~"atomic_xsub_rel" =>
+              { 0u }
               ~"visit_tydesc" | ~"forget" | ~"addr_of" => {
                 0u
               }
diff --git a/src/rustc/middle/typeck/check.rs b/src/rustc/middle/typeck/check.rs
index 7920286fcdd..7b71c59bf26 100644
--- a/src/rustc/middle/typeck/check.rs
+++ b/src/rustc/middle/typeck/check.rs
@@ -2508,16 +2508,6 @@ fn check_intrinsic_type(ccx: @crate_ctxt, it: @ast::foreign_item) {
       }
       ~"needs_drop" => (1u, ~[], ty::mk_bool(tcx)),
 
-      // NB: Old intrinsics.
-      ~"atomic_xchng" | ~"atomic_add" | ~"atomic_sub" |
-      ~"atomic_xchng_acq" | ~"atomic_add_acq" | ~"atomic_sub_acq" |
-      ~"atomic_xchng_rel" | ~"atomic_add_rel" | ~"atomic_sub_rel" => {
-        (0u, ~[arg(ast::by_mutbl_ref, ty::mk_int(tcx)),
-               arg(ast::by_val, ty::mk_int(tcx))],
-         ty::mk_int(tcx))
-      }
-
-      // NB: Transitionary, de-mode-ing.
       ~"atomic_xchg"     | ~"atomic_xadd"     | ~"atomic_xsub" |
       ~"atomic_xchg_acq" | ~"atomic_xadd_acq" | ~"atomic_xsub_acq" |
       ~"atomic_xchg_rel" | ~"atomic_xadd_rel" | ~"atomic_xsub_rel" => {