about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--mk/tests.mk9
-rw-r--r--src/compiletest/common.rs2
-rw-r--r--src/compiletest/compiletest.rs34
-rw-r--r--src/test/bench/rt/msgsend-pipes-shared.rs (renamed from src/test/bench/msgsend-pipes-shared.rs)0
-rw-r--r--src/test/bench/rt/msgsend-pipes.rs (renamed from src/test/bench/msgsend-pipes.rs)0
-rw-r--r--src/test/bench/rt/msgsend-ring-mutex-arcs.rs (renamed from src/test/bench/msgsend-ring-mutex-arcs.rs)0
-rw-r--r--src/test/bench/rt/msgsend-ring-rw-arcs.rs (renamed from src/test/bench/msgsend-ring-rw-arcs.rs)0
-rw-r--r--src/test/bench/rt/rt-messaging-ping-pong.rs (renamed from src/test/bench/rt-messaging-ping-pong.rs)0
-rw-r--r--src/test/bench/rt/rt-parfib.rs (renamed from src/test/bench/rt-parfib.rs)0
-rw-r--r--src/test/bench/rt/rt-spawn-rate.rs (renamed from src/test/bench/rt-spawn-rate.rs)0
-rw-r--r--src/test/bench/rt/task-perf-alloc-unwind.rs (renamed from src/test/bench/task-perf-alloc-unwind.rs)0
-rw-r--r--src/test/bench/rt/task-perf-jargon-metal-smoke.rs (renamed from src/test/bench/task-perf-jargon-metal-smoke.rs)0
-rw-r--r--src/test/bench/rt/task-perf-linked-failure.rs (renamed from src/test/bench/task-perf-linked-failure.rs)0
-rw-r--r--src/test/bench/rt/task-perf-one-million.rs (renamed from src/test/bench/task-perf-one-million.rs)0
-rw-r--r--src/test/bench/rt/task-perf-spawnalot.rs (renamed from src/test/bench/task-perf-spawnalot.rs)0
-rw-r--r--src/test/bench/shootout/shootout-ackermann.rs (renamed from src/test/bench/shootout-ackermann.rs)0
-rw-r--r--src/test/bench/shootout/shootout-binarytrees.rs (renamed from src/test/bench/shootout-binarytrees.rs)0
-rw-r--r--src/test/bench/shootout/shootout-chameneos-redux.rs (renamed from src/test/bench/shootout-chameneos-redux.rs)0
-rw-r--r--src/test/bench/shootout/shootout-fannkuch-redux.rs (renamed from src/test/bench/shootout-fannkuch-redux.rs)0
-rw-r--r--src/test/bench/shootout/shootout-fasta-redux.rs (renamed from src/test/bench/shootout-fasta-redux.rs)0
-rw-r--r--src/test/bench/shootout/shootout-fasta.rs (renamed from src/test/bench/shootout-fasta.rs)0
-rw-r--r--src/test/bench/shootout/shootout-fibo.rs (renamed from src/test/bench/shootout-fibo.rs)0
-rw-r--r--src/test/bench/shootout/shootout-k-nucleotide-pipes.rs (renamed from src/test/bench/shootout-k-nucleotide-pipes.rs)0
-rw-r--r--src/test/bench/shootout/shootout-k-nucleotide.data (renamed from src/test/bench/shootout-k-nucleotide.data)0
-rw-r--r--src/test/bench/shootout/shootout-k-nucleotide.rs (renamed from src/test/bench/shootout-k-nucleotide.rs)0
-rw-r--r--src/test/bench/shootout/shootout-mandelbrot.rs (renamed from src/test/bench/shootout-mandelbrot.rs)0
-rw-r--r--src/test/bench/shootout/shootout-nbody.rs (renamed from src/test/bench/shootout-nbody.rs)0
-rw-r--r--src/test/bench/shootout/shootout-pfib.rs (renamed from src/test/bench/shootout-pfib.rs)0
-rw-r--r--src/test/bench/shootout/shootout-pidigits.rs (renamed from src/test/bench/shootout-pidigits.rs)0
-rw-r--r--src/test/bench/shootout/shootout-reverse-complement.rs (renamed from src/test/bench/shootout-reverse-complement.rs)0
-rw-r--r--src/test/bench/shootout/shootout-spectralnorm.rs (renamed from src/test/bench/shootout-spectralnorm.rs)0
-rw-r--r--src/test/bench/shootout/shootout-threadring.rs (renamed from src/test/bench/shootout-threadring.rs)0
-rw-r--r--src/test/bench/std/core-map.rs (renamed from src/test/bench/core-map.rs)0
-rw-r--r--src/test/bench/std/core-set.rs (renamed from src/test/bench/core-set.rs)0
-rw-r--r--src/test/bench/std/core-std.rs (renamed from src/test/bench/core-std.rs)0
-rw-r--r--src/test/bench/std/core-uint-to-str.rs (renamed from src/test/bench/core-uint-to-str.rs)0
-rw-r--r--src/test/bench/std/std-smallintmap.rs (renamed from src/test/bench/std-smallintmap.rs)0
37 files changed, 24 insertions, 21 deletions
diff --git a/mk/tests.mk b/mk/tests.mk
index 67b2a26c3af..37ce99f4e6e 100644
--- a/mk/tests.mk
+++ b/mk/tests.mk
@@ -476,7 +476,7 @@ RFAIL_RC := $(wildcard $(S)src/test/run-fail/*.rc)
 RFAIL_RS := $(wildcard $(S)src/test/run-fail/*.rs)
 CFAIL_RC := $(wildcard $(S)src/test/compile-fail/*.rc)
 CFAIL_RS := $(wildcard $(S)src/test/compile-fail/*.rs)
-BENCH_RS := $(wildcard $(S)src/test/bench/*.rs)
+BENCH_RS := $(wildcard $(S)src/test/bench/rt/*.rs $(S)src/test/bench/shootout/*.rs $(S)src/test/bench/std/*.rs $(S)src/test/bench/*.rs)
 PRETTY_RS := $(wildcard $(S)src/test/pretty/*.rs)
 DEBUGINFO_RS := $(wildcard $(S)src/test/debug-info/*.rs)
 CODEGEN_RS := $(wildcard $(S)src/test/codegen/*.rs)
@@ -484,7 +484,7 @@ CODEGEN_CC := $(wildcard $(S)src/test/codegen/*.cc)
 
 # perf tests are the same as bench tests only they run under
 # a performance monitor.
-PERF_RS := $(wildcard $(S)src/test/bench/*.rs)
+PERF_RS := $(BENCH_RS)
 
 RPASS_TESTS := $(RPASS_RC) $(RPASS_RS)
 RPASS_FULL_TESTS := $(RPASS_FULL_RC) $(RPASS_FULL_RS)
@@ -516,7 +516,7 @@ CTEST_BUILD_BASE_cfail = compile-fail
 CTEST_MODE_cfail = compile-fail
 CTEST_RUNTOOL_cfail = $(CTEST_RUNTOOL)
 
-CTEST_SRC_BASE_bench = bench
+CTEST_SRC_BASE_bench = bench bench/rt bench/shootout bench/std
 CTEST_BUILD_BASE_bench = bench
 CTEST_MODE_bench = run-pass
 CTEST_RUNTOOL_bench = $(CTEST_RUNTOOL)
@@ -610,7 +610,8 @@ define DEF_RUN_COMPILETEST
 
 CTEST_ARGS$(1)-T-$(2)-H-$(3)-$(4) := \
         $$(CTEST_COMMON_ARGS$(1)-T-$(2)-H-$(3))	\
-        --src-base $$(S)src/test/$$(CTEST_SRC_BASE_$(4))/ \
+        $(foreach base,$$(CTEST_SRC_BASE_$(4)), \
+        --src-base $$(S)src/test/$$(base))/ \
         --build-base $(3)/test/$$(CTEST_BUILD_BASE_$(4))/ \
         --ratchet-metrics $(call TEST_RATCHET_FILE,$(1),$(2),$(3),$(4)) \
         --mode $$(CTEST_MODE_$(4)) \
diff --git a/src/compiletest/common.rs b/src/compiletest/common.rs
index 3ae3600cf88..bbe8026030f 100644
--- a/src/compiletest/common.rs
+++ b/src/compiletest/common.rs
@@ -36,7 +36,7 @@ pub struct config {
     llvm_bin_path: Option<Path>,
 
     // The directory containing the tests to run
-    src_base: Path,
+    src_base: ~[Path],
 
     // The directory where programs should be built
     build_base: Path,
diff --git a/src/compiletest/compiletest.rs b/src/compiletest/compiletest.rs
index 8de79749b54..a186714fd70 100644
--- a/src/compiletest/compiletest.rs
+++ b/src/compiletest/compiletest.rs
@@ -19,7 +19,7 @@ use std::os;
 use std::f64;
 
 use extra::getopts;
-use extra::getopts::groups::{optopt, optflag, reqopt};
+use extra::getopts::groups::{optopt, optflag, reqopt, optmulti};
 use extra::test;
 
 use common::config;
@@ -49,19 +49,19 @@ pub fn main() {
 pub fn parse_config(args: ~[~str]) -> config {
 
     let groups : ~[getopts::groups::OptGroup] =
-        ~[reqopt("", "compile-lib-path", "path to host shared libraries", "PATH"),
-          reqopt("", "run-lib-path", "path to target shared libraries", "PATH"),
-          reqopt("", "rustc-path", "path to rustc to use for compiling", "PATH"),
-          optopt("", "clang-path", "path to  executable for codegen tests", "PATH"),
-          optopt("", "llvm-bin-path", "path to directory holding llvm binaries", "DIR"),
-          reqopt("", "src-base", "directory to scan for test files", "PATH"),
-          reqopt("", "build-base", "directory to deposit test outputs", "PATH"),
-          reqopt("", "aux-base", "directory to find auxiliary test files", "PATH"),
-          reqopt("", "stage-id", "the target-stage identifier", "stageN-TARGET"),
-          reqopt("", "mode", "which sort of compile tests to run",
-                 "(compile-fail|run-fail|run-pass|pretty|debug-info)"),
-          optflag("", "ignored", "run tests marked as ignored / xfailed"),
-          optopt("", "runtool", "supervisor program to run tests under \
+        ~[reqopt   ("", "compile-lib-path", "path to host shared libraries", "PATH"),
+          reqopt   ("", "run-lib-path", "path to target shared libraries", "PATH"),
+          reqopt   ("", "rustc-path", "path to rustc to use for compiling", "PATH"),
+          optopt   ("", "clang-path", "path to  executable for codegen tests", "PATH"),
+          optopt   ("", "llvm-bin-path", "path to directory holding llvm binaries", "DIR"),
+          optmulti ("", "src-base", "directory to scan for test files", "PATH"),
+          reqopt   ("", "build-base", "directory to deposit test outputs", "PATH"),
+          reqopt   ("", "aux-base", "directory to find auxiliary test files", "PATH"),
+          reqopt   ("", "stage-id", "the target-stage identifier", "stageN-TARGET"),
+          reqopt   ("", "mode", "which sort of compile tests to run",
+                    " (compile-fail|run-fail|run-pass|pretty|debug-info)"),
+          optflag  ("", "ignored", "run tests marked as ignored / xfailed"),
+          optopt   ("", "runtool", "supervisor program to run tests under \
                                  (eg. emulator, valgrind)", "PROGRAM"),
           optopt("", "rustcflags", "flags to pass to rustc", "FLAGS"),
           optflag("", "verbose", "run tests verbosely, showing all output"),
@@ -106,13 +106,15 @@ pub fn parse_config(args: ~[~str]) -> config {
         Path(getopts::opt_str(m, nm))
     }
 
+    let src_base = getopts::opt_strs(matches, "src-base");
+
     config {
         compile_lib_path: getopts::opt_str(matches, "compile-lib-path"),
         run_lib_path: getopts::opt_str(matches, "run-lib-path"),
         rustc_path: opt_path(matches, "rustc-path"),
         clang_path: getopts::opt_maybe_str(matches, "clang-path").map_move(|s| Path(s)),
         llvm_bin_path: getopts::opt_maybe_str(matches, "llvm-bin-path").map_move(|s| Path(s)),
-        src_base: opt_path(matches, "src-base"),
+        src_base: src_base.iter().map(|x| Path(x.clone())).collect(),
         build_base: opt_path(matches, "build-base"),
         aux_base: opt_path(matches, "aux-base"),
         stage_id: getopts::opt_str(matches, "stage-id"),
@@ -248,7 +250,7 @@ pub fn make_tests(config: &config) -> ~[test::TestDescAndFn] {
     debug!("making tests from %s",
            config.src_base.to_str());
     let mut tests = ~[];
-    let dirs = os::list_dir_path(&config.src_base);
+    let dirs = config.src_base.iter().flat_map(|x| os::list_dir_path(x).move_iter()).to_owned_vec();
     for file in dirs.iter() {
         let file = file.clone();
         debug!("inspecting file %s", file.to_str());
diff --git a/src/test/bench/msgsend-pipes-shared.rs b/src/test/bench/rt/msgsend-pipes-shared.rs
index 4e9656afb81..4e9656afb81 100644
--- a/src/test/bench/msgsend-pipes-shared.rs
+++ b/src/test/bench/rt/msgsend-pipes-shared.rs
diff --git a/src/test/bench/msgsend-pipes.rs b/src/test/bench/rt/msgsend-pipes.rs
index 470e23d63a5..470e23d63a5 100644
--- a/src/test/bench/msgsend-pipes.rs
+++ b/src/test/bench/rt/msgsend-pipes.rs
diff --git a/src/test/bench/msgsend-ring-mutex-arcs.rs b/src/test/bench/rt/msgsend-ring-mutex-arcs.rs
index a5311d5c831..a5311d5c831 100644
--- a/src/test/bench/msgsend-ring-mutex-arcs.rs
+++ b/src/test/bench/rt/msgsend-ring-mutex-arcs.rs
diff --git a/src/test/bench/msgsend-ring-rw-arcs.rs b/src/test/bench/rt/msgsend-ring-rw-arcs.rs
index e25490bcd9b..e25490bcd9b 100644
--- a/src/test/bench/msgsend-ring-rw-arcs.rs
+++ b/src/test/bench/rt/msgsend-ring-rw-arcs.rs
diff --git a/src/test/bench/rt-messaging-ping-pong.rs b/src/test/bench/rt/rt-messaging-ping-pong.rs
index 6c482c6d207..6c482c6d207 100644
--- a/src/test/bench/rt-messaging-ping-pong.rs
+++ b/src/test/bench/rt/rt-messaging-ping-pong.rs
diff --git a/src/test/bench/rt-parfib.rs b/src/test/bench/rt/rt-parfib.rs
index 32f0a592273..32f0a592273 100644
--- a/src/test/bench/rt-parfib.rs
+++ b/src/test/bench/rt/rt-parfib.rs
diff --git a/src/test/bench/rt-spawn-rate.rs b/src/test/bench/rt/rt-spawn-rate.rs
index ff578ed70b9..ff578ed70b9 100644
--- a/src/test/bench/rt-spawn-rate.rs
+++ b/src/test/bench/rt/rt-spawn-rate.rs
diff --git a/src/test/bench/task-perf-alloc-unwind.rs b/src/test/bench/rt/task-perf-alloc-unwind.rs
index 9718a12c83f..9718a12c83f 100644
--- a/src/test/bench/task-perf-alloc-unwind.rs
+++ b/src/test/bench/rt/task-perf-alloc-unwind.rs
diff --git a/src/test/bench/task-perf-jargon-metal-smoke.rs b/src/test/bench/rt/task-perf-jargon-metal-smoke.rs
index 0020a006e68..0020a006e68 100644
--- a/src/test/bench/task-perf-jargon-metal-smoke.rs
+++ b/src/test/bench/rt/task-perf-jargon-metal-smoke.rs
diff --git a/src/test/bench/task-perf-linked-failure.rs b/src/test/bench/rt/task-perf-linked-failure.rs
index 7788005775f..7788005775f 100644
--- a/src/test/bench/task-perf-linked-failure.rs
+++ b/src/test/bench/rt/task-perf-linked-failure.rs
diff --git a/src/test/bench/task-perf-one-million.rs b/src/test/bench/rt/task-perf-one-million.rs
index 5efe13f8bca..5efe13f8bca 100644
--- a/src/test/bench/task-perf-one-million.rs
+++ b/src/test/bench/rt/task-perf-one-million.rs
diff --git a/src/test/bench/task-perf-spawnalot.rs b/src/test/bench/rt/task-perf-spawnalot.rs
index 83116ae3c87..83116ae3c87 100644
--- a/src/test/bench/task-perf-spawnalot.rs
+++ b/src/test/bench/rt/task-perf-spawnalot.rs
diff --git a/src/test/bench/shootout-ackermann.rs b/src/test/bench/shootout/shootout-ackermann.rs
index 3ecb580874c..3ecb580874c 100644
--- a/src/test/bench/shootout-ackermann.rs
+++ b/src/test/bench/shootout/shootout-ackermann.rs
diff --git a/src/test/bench/shootout-binarytrees.rs b/src/test/bench/shootout/shootout-binarytrees.rs
index 8a2ae3e8995..8a2ae3e8995 100644
--- a/src/test/bench/shootout-binarytrees.rs
+++ b/src/test/bench/shootout/shootout-binarytrees.rs
diff --git a/src/test/bench/shootout-chameneos-redux.rs b/src/test/bench/shootout/shootout-chameneos-redux.rs
index f82c5e692e4..f82c5e692e4 100644
--- a/src/test/bench/shootout-chameneos-redux.rs
+++ b/src/test/bench/shootout/shootout-chameneos-redux.rs
diff --git a/src/test/bench/shootout-fannkuch-redux.rs b/src/test/bench/shootout/shootout-fannkuch-redux.rs
index 48372c6d03b..48372c6d03b 100644
--- a/src/test/bench/shootout-fannkuch-redux.rs
+++ b/src/test/bench/shootout/shootout-fannkuch-redux.rs
diff --git a/src/test/bench/shootout-fasta-redux.rs b/src/test/bench/shootout/shootout-fasta-redux.rs
index 1f1ce86404b..1f1ce86404b 100644
--- a/src/test/bench/shootout-fasta-redux.rs
+++ b/src/test/bench/shootout/shootout-fasta-redux.rs
diff --git a/src/test/bench/shootout-fasta.rs b/src/test/bench/shootout/shootout-fasta.rs
index 9d47e7fed23..9d47e7fed23 100644
--- a/src/test/bench/shootout-fasta.rs
+++ b/src/test/bench/shootout/shootout-fasta.rs
diff --git a/src/test/bench/shootout-fibo.rs b/src/test/bench/shootout/shootout-fibo.rs
index a367beface2..a367beface2 100644
--- a/src/test/bench/shootout-fibo.rs
+++ b/src/test/bench/shootout/shootout-fibo.rs
diff --git a/src/test/bench/shootout-k-nucleotide-pipes.rs b/src/test/bench/shootout/shootout-k-nucleotide-pipes.rs
index 0a036696544..0a036696544 100644
--- a/src/test/bench/shootout-k-nucleotide-pipes.rs
+++ b/src/test/bench/shootout/shootout-k-nucleotide-pipes.rs
diff --git a/src/test/bench/shootout-k-nucleotide.data b/src/test/bench/shootout/shootout-k-nucleotide.data
index 9ba8f4861d2..9ba8f4861d2 100644
--- a/src/test/bench/shootout-k-nucleotide.data
+++ b/src/test/bench/shootout/shootout-k-nucleotide.data
diff --git a/src/test/bench/shootout-k-nucleotide.rs b/src/test/bench/shootout/shootout-k-nucleotide.rs
index 2b5b4ded947..2b5b4ded947 100644
--- a/src/test/bench/shootout-k-nucleotide.rs
+++ b/src/test/bench/shootout/shootout-k-nucleotide.rs
diff --git a/src/test/bench/shootout-mandelbrot.rs b/src/test/bench/shootout/shootout-mandelbrot.rs
index 72007d2b50a..72007d2b50a 100644
--- a/src/test/bench/shootout-mandelbrot.rs
+++ b/src/test/bench/shootout/shootout-mandelbrot.rs
diff --git a/src/test/bench/shootout-nbody.rs b/src/test/bench/shootout/shootout-nbody.rs
index 0f43d5027a9..0f43d5027a9 100644
--- a/src/test/bench/shootout-nbody.rs
+++ b/src/test/bench/shootout/shootout-nbody.rs
diff --git a/src/test/bench/shootout-pfib.rs b/src/test/bench/shootout/shootout-pfib.rs
index b2491e305b2..b2491e305b2 100644
--- a/src/test/bench/shootout-pfib.rs
+++ b/src/test/bench/shootout/shootout-pfib.rs
diff --git a/src/test/bench/shootout-pidigits.rs b/src/test/bench/shootout/shootout-pidigits.rs
index e84a4ea4327..e84a4ea4327 100644
--- a/src/test/bench/shootout-pidigits.rs
+++ b/src/test/bench/shootout/shootout-pidigits.rs
diff --git a/src/test/bench/shootout-reverse-complement.rs b/src/test/bench/shootout/shootout-reverse-complement.rs
index 6ce62ccd127..6ce62ccd127 100644
--- a/src/test/bench/shootout-reverse-complement.rs
+++ b/src/test/bench/shootout/shootout-reverse-complement.rs
diff --git a/src/test/bench/shootout-spectralnorm.rs b/src/test/bench/shootout/shootout-spectralnorm.rs
index d7f5e5781e0..d7f5e5781e0 100644
--- a/src/test/bench/shootout-spectralnorm.rs
+++ b/src/test/bench/shootout/shootout-spectralnorm.rs
diff --git a/src/test/bench/shootout-threadring.rs b/src/test/bench/shootout/shootout-threadring.rs
index ace008c1f95..ace008c1f95 100644
--- a/src/test/bench/shootout-threadring.rs
+++ b/src/test/bench/shootout/shootout-threadring.rs
diff --git a/src/test/bench/core-map.rs b/src/test/bench/std/core-map.rs
index 2571d601459..2571d601459 100644
--- a/src/test/bench/core-map.rs
+++ b/src/test/bench/std/core-map.rs
diff --git a/src/test/bench/core-set.rs b/src/test/bench/std/core-set.rs
index fe77196e2b1..fe77196e2b1 100644
--- a/src/test/bench/core-set.rs
+++ b/src/test/bench/std/core-set.rs
diff --git a/src/test/bench/core-std.rs b/src/test/bench/std/core-std.rs
index 6735d623e6c..6735d623e6c 100644
--- a/src/test/bench/core-std.rs
+++ b/src/test/bench/std/core-std.rs
diff --git a/src/test/bench/core-uint-to-str.rs b/src/test/bench/std/core-uint-to-str.rs
index 4869c486e5e..4869c486e5e 100644
--- a/src/test/bench/core-uint-to-str.rs
+++ b/src/test/bench/std/core-uint-to-str.rs
diff --git a/src/test/bench/std-smallintmap.rs b/src/test/bench/std/std-smallintmap.rs
index a035041a662..a035041a662 100644
--- a/src/test/bench/std-smallintmap.rs
+++ b/src/test/bench/std/std-smallintmap.rs