File tree 12 files changed +16
-16
lines changed
sanitizer-invalid-cratetype
12 files changed +16
-16
lines changed Original file line number Diff line number Diff line change @@ -1268,11 +1268,11 @@ impl Step for Compiletest {
1268
1268
builder. add_rust_test_threads ( & mut cmd) ;
1269
1269
1270
1270
if builder. config . sanitizers {
1271
- cmd. env ( "SANITIZER_SUPPORT " , "1" ) ;
1271
+ cmd. env ( "RUSTC_SANITIZER_SUPPORT " , "1" ) ;
1272
1272
}
1273
1273
1274
1274
if builder. config . profiler {
1275
- cmd. env ( "PROFILER_SUPPORT " , "1" ) ;
1275
+ cmd. env ( "RUSTC_PROFILER_SUPPORT " , "1" ) ;
1276
1276
}
1277
1277
1278
1278
cmd. env ( "RUST_TEST_TMPDIR" , builder. out . join ( "tmp" ) ) ;
Original file line number Diff line number Diff line change 1
1
-include ../tools.mk
2
2
3
3
all :
4
- ifeq ($(PROFILER_SUPPORT ) ,1)
4
+ ifeq ($(RUSTC_PROFILER_SUPPORT ) ,1)
5
5
$(RUSTC) -Copt-level=3 -Clto=fat -Z pgo-gen="$(TMPDIR)" test.rs
6
6
$(call RUN,test) || exit 1
7
7
[ -e "$(TMPDIR)"/default_*.profraw ] || (echo "No .profraw file"; exit 1)
Original file line number Diff line number Diff line change 1
1
-include ../tools.mk
2
2
3
3
all :
4
- ifeq ($(PROFILER_SUPPORT ) ,1)
4
+ ifeq ($(RUSTC_PROFILER_SUPPORT ) ,1)
5
5
$(RUSTC) -O -Ccodegen-units=1 -Z pgo-gen="$(TMPDIR)" --emit=llvm-ir test.rs
6
6
# We expect symbols starting with "__llvm_profile_".
7
7
$(CGREP) "__llvm_profile_" < $(TMPDIR)/test.ll
Original file line number Diff line number Diff line change 1
1
-include ../tools.mk
2
2
3
3
all :
4
- ifeq ($(PROFILER_SUPPORT ) ,1)
4
+ ifeq ($(RUSTC_PROFILER_SUPPORT ) ,1)
5
5
$(RUSTC) -g -Z pgo-gen="$(TMPDIR)" test.rs
6
6
$(call RUN,test) || exit 1
7
7
[ -e "$(TMPDIR)"/default_*.profraw ] || (echo "No .profraw file"; exit 1)
Original file line number Diff line number Diff line change 1
1
-include ../tools.mk
2
2
3
3
all :
4
- ifeq ($(PROFILER_SUPPORT ) ,1)
4
+ ifeq ($(RUSTC_PROFILER_SUPPORT ) ,1)
5
5
$(RUSTC) -g -Z profile test.rs
6
6
$(call RUN,test) || exit 1
7
7
[ -e "$(TMPDIR)/test.gcno" ] || (echo "No .gcno file"; exit 1)
Original file line number Diff line number Diff line change @@ -5,11 +5,11 @@ LOG := $(TMPDIR)/log.txt
5
5
# NOTE the address sanitizer only supports x86_64 linux and macOS
6
6
7
7
ifeq ($(TARGET ) ,x86_64-apple-darwin)
8
- ASAN_SUPPORT =$(SANITIZER_SUPPORT )
8
+ ASAN_SUPPORT =$(RUSTC_SANITIZER_SUPPORT )
9
9
EXTRA_RUSTFLAG =-C rpath
10
10
else
11
11
ifeq ($(TARGET ) ,x86_64-unknown-linux-gnu)
12
- ASAN_SUPPORT =$(SANITIZER_SUPPORT )
12
+ ASAN_SUPPORT =$(RUSTC_SANITIZER_SUPPORT )
13
13
14
14
# Apparently there are very specific Linux kernels, notably the one that's
15
15
# currently on Travis CI, which contain a buggy commit that triggers failures in
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ LOG := $(TMPDIR)/log.txt
8
8
# is correctly detected.
9
9
10
10
ifeq ($(TARGET ) ,x86_64-unknown-linux-gnu)
11
- ASAN_SUPPORT =$(SANITIZER_SUPPORT )
11
+ ASAN_SUPPORT =$(RUSTC_SANITIZER_SUPPORT )
12
12
13
13
# See comment in sanitizer-address/Makefile for why this is here
14
14
EXTRA_RUSTFLAG =-C relocation-model=dynamic-no-pic
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ LOG := $(TMPDIR)/log.txt
8
8
# is correctly detected.
9
9
10
10
ifeq ($(TARGET ) ,x86_64-unknown-linux-gnu)
11
- ASAN_SUPPORT =$(SANITIZER_SUPPORT )
11
+ ASAN_SUPPORT =$(RUSTC_SANITIZER_SUPPORT )
12
12
13
13
# See comment in sanitizer-address/Makefile for why this is here
14
14
EXTRA_RUSTFLAG =-C relocation-model=dynamic-no-pic
Original file line number Diff line number Diff line change 3
3
# NOTE the address sanitizer only supports x86_64 linux and macOS
4
4
5
5
ifeq ($(TARGET ) ,x86_64-apple-darwin)
6
- ASAN_SUPPORT =$(SANITIZER_SUPPORT )
6
+ ASAN_SUPPORT =$(RUSTC_SANITIZER_SUPPORT )
7
7
EXTRA_RUSTFLAG =-C rpath
8
8
else
9
9
ifeq ($(TARGET ) ,x86_64-unknown-linux-gnu)
10
- ASAN_SUPPORT =$(SANITIZER_SUPPORT )
10
+ ASAN_SUPPORT =$(RUSTC_SANITIZER_SUPPORT )
11
11
EXTRA_RUSTFLAG =
12
12
endif
13
13
endif
Original file line number Diff line number Diff line change 6
6
# FIXME(#46126) ThinLTO for libstd broke this test
7
7
8
8
all :
9
- ifdef SANITIZER_SUPPORT
9
+ ifdef RUSTC_SANITIZER_SUPPORT
10
10
$(RUSTC) -C opt-level=1 -g -Z sanitizer=leak -Z print-link-args leak.rs | $(CGREP) librustc_lsan
11
11
$(TMPDIR)/leak 2>&1 | $(CGREP) 'detected memory leaks'
12
12
endif
Original file line number Diff line number Diff line change 4
4
# only-x86_64
5
5
6
6
all :
7
- ifdef SANITIZER_SUPPORT
7
+ ifdef RUSTC_SANITIZER_SUPPORT
8
8
$(RUSTC) -g -Z sanitizer=memory -Z print-link-args uninit.rs | $(CGREP) librustc_msan
9
9
$(TMPDIR)/uninit 2>&1 | $(CGREP) use-of-uninitialized-value
10
10
endif
Original file line number Diff line number Diff line change 1
1
-include ../tools.mk
2
2
3
3
# This test builds a staticlib, then an executable that links to it.
4
- # The staticlib and executable both are compiled with address sanitizer,
4
+ # The staticlib and executable both are compiled with address sanitizer,
5
5
# and we assert that a fault in the staticlib is correctly detected.
6
6
7
7
ifeq ($(TARGET ) ,x86_64-unknown-linux-gnu)
8
- ASAN_SUPPORT =$(SANITIZER_SUPPORT )
8
+ ASAN_SUPPORT =$(RUSTC_SANITIZER_SUPPORT )
9
9
EXTRA_RUSTFLAG =
10
10
endif
11
11
You can’t perform that action at this time.
0 commit comments