mirror of
https://github.com/rust-lang/rust
synced 2024-09-05 00:24:52 +00:00
mk: Remove all perf-related targets
I don't believe these have been used at all recently, and I doubt many of them still work, so remove the stale support.
This commit is contained in:
parent
46dcffd05b
commit
5cd9ca90c5
|
@ -220,19 +220,12 @@ endif
|
|||
# The test suite
|
||||
ifneq ($(strip $(findstring check,$(MAKECMDGOALS)) \
|
||||
$(findstring test,$(MAKECMDGOALS)) \
|
||||
$(findstring perf,$(MAKECMDGOALS)) \
|
||||
$(findstring tidy,$(MAKECMDGOALS))),)
|
||||
CFG_INFO := $(info cfg: including test rules)
|
||||
include $(CFG_SRC_DIR)mk/tests.mk
|
||||
include $(CFG_SRC_DIR)mk/grammar.mk
|
||||
endif
|
||||
|
||||
# Performance and benchmarking
|
||||
ifneq ($(findstring perf,$(MAKECMDGOALS)),)
|
||||
CFG_INFO := $(info cfg: including perf rules)
|
||||
include $(CFG_SRC_DIR)mk/perf.mk
|
||||
endif
|
||||
|
||||
# Copy all the distributables to another directory for binary install
|
||||
ifneq ($(strip $(findstring prepare,$(MAKECMDGOALS)) \
|
||||
$(findstring dist,$(MAKECMDGOALS)) \
|
||||
|
|
|
@ -522,14 +522,6 @@ STAGE$(1)_T_$(2)_H_$(3) := \
|
|||
$$(CFG_RUSTC_FLAGS) $$(EXTRAFLAGS_STAGE$(1)) --target=$(2)) \
|
||||
$$(RUSTC_FLAGS_$(2))
|
||||
|
||||
PERF_STAGE$(1)_T_$(2)_H_$(3) := \
|
||||
$$(Q)$$(call CFG_RUN_TARG_$(3),$(1), \
|
||||
$$(CFG_PERF_TOOL) \
|
||||
$$(HBIN$(1)_H_$(3))/rustc$$(X_$(3)) \
|
||||
--cfg $$(CFGFLAG$(1)_T_$(2)_H_$(3)) \
|
||||
$$(CFG_RUSTC_FLAGS) $$(EXTRAFLAGS_STAGE$(1)) --target=$(2)) \
|
||||
$$(RUSTC_FLAGS_$(2))
|
||||
|
||||
endef
|
||||
|
||||
$(foreach build,$(CFG_HOST), \
|
||||
|
|
25
mk/perf.mk
25
mk/perf.mk
|
@ -1,25 +0,0 @@
|
|||
# Copyright 2012 The Rust Project Developers. See the COPYRIGHT
|
||||
# file at the top-level directory of this distribution and at
|
||||
# http://rust-lang.org/COPYRIGHT.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
|
||||
# http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
|
||||
# <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
|
||||
# option. This file may not be copied, modified, or distributed
|
||||
# except according to those terms.
|
||||
|
||||
|
||||
ifdef CFG_PERF_TOOL
|
||||
rustc-perf$(X): $(CFG_BUILD)/stage2/bin/rustc$(X_$(CFG_BUILD))
|
||||
@$(call E, perf compile: $@)
|
||||
$(PERF_STAGE2_T_$(CFG_BUILD)_H_$(CFG_BUILD)) \
|
||||
-o $@ $(COMPILER_CRATE) >rustc-perf.err 2>&1
|
||||
$(Q)rm -f $(LIBRUSTC_GLOB)
|
||||
else
|
||||
rustc-perf$(X): $(CFG_BUILD)/stage2/bin/rustc$(X_$(CFG_BUILD))
|
||||
$(Q)touch $@
|
||||
endif
|
||||
|
||||
perf: check-stage2-perf rustc-perf$(X_$(CFG_BUILD))
|
||||
$(Q)find $(CFG_BUILD)/test/perf -name \*.err | xargs cat
|
||||
$(Q)cat rustc-perf.err
|
|
@ -77,23 +77,6 @@ define DEF_GOOD_VALGRIND
|
|||
endef
|
||||
$(foreach t,$(CFG_TARGET),$(eval $(call DEF_GOOD_VALGRIND,$(t))))
|
||||
|
||||
ifneq ($(findstring linux,$(CFG_OSTYPE)),)
|
||||
ifdef CFG_PERF
|
||||
ifneq ($(CFG_PERF_WITH_LOGFD),)
|
||||
CFG_PERF_TOOL := $(CFG_PERF) stat -r 3 --log-fd 2
|
||||
else
|
||||
CFG_PERF_TOOL := $(CFG_PERF) stat -r 3
|
||||
endif
|
||||
else
|
||||
ifdef CFG_VALGRIND
|
||||
CFG_PERF_TOOL := \
|
||||
$(CFG_VALGRIND) --tool=cachegrind --cache-sim=yes --branch-sim=yes
|
||||
else
|
||||
CFG_PERF_TOOL := /usr/bin/time --verbose
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
AR := ar
|
||||
|
||||
define SET_FROM_CFG
|
||||
|
|
27
mk/tests.mk
27
mk/tests.mk
|
@ -50,11 +50,6 @@ ifdef CFG_VALGRIND
|
|||
CTEST_RUNTOOL = --runtool "$(CFG_VALGRIND)"
|
||||
endif
|
||||
|
||||
# Arguments to the perf tests
|
||||
ifdef CFG_PERF_TOOL
|
||||
CTEST_PERF_RUNTOOL = --runtool "$(CFG_PERF_TOOL)"
|
||||
endif
|
||||
|
||||
CTEST_TESTARGS := $(TESTARGS)
|
||||
|
||||
# --bench is only relevant for crate tests, not for the compile tests
|
||||
|
@ -70,12 +65,6 @@ endif
|
|||
# This prevents tests from failing with some locales (fixes #17423).
|
||||
export LC_ALL=C
|
||||
|
||||
# If we're running perf then set this environment variable
|
||||
# to put the benchmarks into 'hard mode'
|
||||
ifeq ($(MAKECMDGOALS),perf)
|
||||
export RUST_BENCH=1
|
||||
endif
|
||||
|
||||
TEST_LOG_FILE=tmp/check-stage$(1)-T-$(2)-H-$(3)-$(4).log
|
||||
TEST_OK_FILE=tmp/check-stage$(1)-T-$(2)-H-$(3)-$(4).ok
|
||||
|
||||
|
@ -486,10 +475,6 @@ CODEGEN_RS := $(wildcard $(S)src/test/codegen/*.rs)
|
|||
CODEGEN_CC := $(wildcard $(S)src/test/codegen/*.cc)
|
||||
RUSTDOCCK_RS := $(wildcard $(S)src/test/rustdoc/*.rs)
|
||||
|
||||
# perf tests are the same as bench tests only they run under
|
||||
# a performance monitor.
|
||||
PERF_RS := $(wildcard $(S)src/test/bench/*.rs)
|
||||
|
||||
RPASS_TESTS := $(RPASS_RS)
|
||||
RPASS_VALGRIND_TESTS := $(RPASS_VALGRIND_RS)
|
||||
RPASS_FULL_TESTS := $(RPASS_FULL_RS)
|
||||
|
@ -499,7 +484,6 @@ RFAIL_TESTS := $(RFAIL_RS)
|
|||
CFAIL_TESTS := $(CFAIL_RS)
|
||||
PFAIL_TESTS := $(PFAIL_RS)
|
||||
BENCH_TESTS := $(BENCH_RS)
|
||||
PERF_TESTS := $(PERF_RS)
|
||||
PRETTY_TESTS := $(PRETTY_RS)
|
||||
DEBUGINFO_GDB_TESTS := $(DEBUGINFO_GDB_RS)
|
||||
DEBUGINFO_LLDB_TESTS := $(DEBUGINFO_LLDB_RS)
|
||||
|
@ -551,11 +535,6 @@ CTEST_BUILD_BASE_bench = bench
|
|||
CTEST_MODE_bench = run-pass
|
||||
CTEST_RUNTOOL_bench = $(CTEST_RUNTOOL)
|
||||
|
||||
CTEST_SRC_BASE_perf = bench
|
||||
CTEST_BUILD_BASE_perf = perf
|
||||
CTEST_MODE_perf = run-pass
|
||||
CTEST_RUNTOOL_perf = $(CTEST_PERF_RUNTOOL)
|
||||
|
||||
CTEST_SRC_BASE_debuginfo-gdb = debuginfo
|
||||
CTEST_BUILD_BASE_debuginfo-gdb = debuginfo-gdb
|
||||
CTEST_MODE_debuginfo-gdb = debuginfo-gdb
|
||||
|
@ -625,7 +604,7 @@ TEST_SREQ$(1)_T_$(2)_H_$(3) = \
|
|||
$$(HBIN$(1)_H_$(3))/compiletest$$(X_$(3)) \
|
||||
$$(SREQ$(1)_T_$(2)_H_$(3))
|
||||
|
||||
# Rules for the cfail/rfail/rpass/bench/perf test runner
|
||||
# Rules for the cfail/rfail/rpass/bench test runner
|
||||
|
||||
# The tests select when to use debug configuration on their own;
|
||||
# remove directive, if present, from CFG_RUSTC_FLAGS (issue #7898).
|
||||
|
@ -689,7 +668,6 @@ CTEST_DEPS_rfail_$(1)-T-$(2)-H-$(3) = $$(RFAIL_TESTS)
|
|||
CTEST_DEPS_cfail_$(1)-T-$(2)-H-$(3) = $$(CFAIL_TESTS)
|
||||
CTEST_DEPS_pfail_$(1)-T-$(2)-H-$(3) = $$(PFAIL_TESTS)
|
||||
CTEST_DEPS_bench_$(1)-T-$(2)-H-$(3) = $$(BENCH_TESTS)
|
||||
CTEST_DEPS_perf_$(1)-T-$(2)-H-$(3) = $$(PERF_TESTS)
|
||||
CTEST_DEPS_debuginfo-gdb_$(1)-T-$(2)-H-$(3) = $$(DEBUGINFO_GDB_TESTS)
|
||||
CTEST_DEPS_debuginfo-lldb_$(1)-T-$(2)-H-$(3) = $$(DEBUGINFO_LLDB_TESTS) \
|
||||
$(S)src/etc/lldb_batchmode.py \
|
||||
|
@ -761,7 +739,7 @@ endif
|
|||
endef
|
||||
|
||||
CTEST_NAMES = rpass rpass-valgrind rpass-full rfail-full cfail-full rfail cfail pfail \
|
||||
bench perf debuginfo-gdb debuginfo-lldb codegen rustdocck
|
||||
bench debuginfo-gdb debuginfo-lldb codegen rustdocck
|
||||
|
||||
$(foreach host,$(CFG_HOST), \
|
||||
$(eval $(foreach target,$(CFG_TARGET), \
|
||||
|
@ -934,7 +912,6 @@ TEST_GROUPS = \
|
|||
cfail \
|
||||
pfail \
|
||||
bench \
|
||||
perf \
|
||||
rmake \
|
||||
rustdocck \
|
||||
debuginfo-gdb \
|
||||
|
|
Loading…
Reference in a new issue