Skip to content

Commit d260e34

Browse files
ci: add new job sanitize-address-clang-without-gc that passes -gc none through VFLAGS (#25780)
* ci: new job sanitize-address-clang-without-gc * ci: mark map_generic_call_test.v and comptime_map_it_test.v for skipping on the new sanitize-address-clang-without-gc job --------- Co-authored-by: Delyan Angelov <delian66@gmail.com>
1 parent 416e5ee commit d260e34

File tree

3 files changed

+33
-5
lines changed

3 files changed

+33
-5
lines changed

.github/workflows/sanitized_ci.yml

Lines changed: 31 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ jobs:
9393
run: ./v -silent test-cleancode
9494
- name: Install dependencies
9595
run: |
96-
.github/workflows/disable_azure_mirror.sh
96+
.github/workflows/disable_azure_mirror.sh
9797
./v retry -- sudo apt update
9898
./v retry -- sudo apt install --quiet -y postgresql libpq-dev libssl-dev sqlite3 libsqlite3-dev valgrind
9999
./v retry -- sudo apt install --quiet -y libfreetype6-dev libxi-dev libxcursor-dev libgl-dev libxrandr-dev libasound2-dev
@@ -123,7 +123,7 @@ jobs:
123123
run: ./v -silent test-cleancode
124124
- name: Install dependencies
125125
run: |
126-
.github/workflows/disable_azure_mirror.sh
126+
.github/workflows/disable_azure_mirror.sh
127127
./v retry -- sudo apt update
128128
./v retry -- sudo apt install --quiet -y postgresql libpq-dev libssl-dev sqlite3 libsqlite3-dev valgrind
129129
./v retry -- sudo apt install --quiet -y libfreetype6-dev libxi-dev libxcursor-dev libgl-dev libxrandr-dev libasound2-dev
@@ -153,7 +153,7 @@ jobs:
153153
run: ./v -silent test-cleancode
154154
- name: Install dependencies
155155
run: |
156-
.github/workflows/disable_azure_mirror.sh
156+
.github/workflows/disable_azure_mirror.sh
157157
./v retry -- sudo apt update
158158
./v retry -- sudo apt install --quiet -y postgresql libpq-dev libssl-dev sqlite3 libsqlite3-dev valgrind
159159
./v retry -- sudo apt install --quiet -y libfreetype6-dev libxi-dev libxcursor-dev libgl-dev libxrandr-dev libasound2-dev
@@ -210,7 +210,7 @@ jobs:
210210
run: ./v -silent test-cleancode
211211
- name: Install dependencies
212212
run: |
213-
.github/workflows/disable_azure_mirror.sh
213+
.github/workflows/disable_azure_mirror.sh
214214
./v retry -- sudo apt update
215215
./v retry -- sudo apt install --quiet -y postgresql libpq-dev libssl-dev sqlite3 libsqlite3-dev valgrind
216216
./v retry -- sudo apt install --quiet -y libfreetype6-dev libxi-dev libxcursor-dev libgl-dev libxrandr-dev libasound2-dev
@@ -241,7 +241,7 @@ jobs:
241241
run: ./v -silent test-cleancode
242242
- name: Install dependencies
243243
run: |
244-
.github/workflows/disable_azure_mirror.sh
244+
.github/workflows/disable_azure_mirror.sh
245245
./v retry -- sudo apt update
246246
./v retry -- sudo apt install --quiet -y postgresql libpq-dev libssl-dev sqlite3 libsqlite3-dev valgrind
247247
./v retry -- sudo apt install --quiet -y libfreetype6-dev libxi-dev libxcursor-dev libgl-dev libxrandr-dev libasound2-dev
@@ -256,3 +256,29 @@ jobs:
256256
./v -cc tcc -silent test-self -msan-compiler vlib
257257
- name: Build examples (V compiled with -fsanitize=memory)
258258
run: ./v -silent build-examples
259+
260+
sanitize-address-clang-without-gc:
261+
runs-on: ubuntu-22.04
262+
timeout-minutes: 300
263+
env:
264+
VFLAGS: -cc clang -gc none -cflags -fno-omit-frame-pointer
265+
VJOBS: 1
266+
LSAN_OPTIONS: detect_leaks=0
267+
VNATIVE_SKIP_LIBC_VV: 1
268+
steps:
269+
- uses: actions/checkout@v5
270+
- name: Build V
271+
run: make -j4 && ./v symlink
272+
- name: Ensure code is well formatted
273+
run: ./v -silent test-cleancode
274+
- name: Install dependencies
275+
run: |
276+
.github/workflows/disable_azure_mirror.sh
277+
./v retry -- sudo apt update
278+
./v retry -- sudo apt install --quiet -y postgresql libpq-dev libssl-dev sqlite3 libsqlite3-dev valgrind
279+
./v retry -- sudo apt install --quiet -y libfreetype6-dev libxi-dev libxcursor-dev libgl-dev libxrandr-dev libasound2-dev
280+
./v retry -- sudo apt install clang
281+
- name: Recompile V with -cstrict
282+
run: ./v -cg -cstrict -o v cmd/v
283+
- name: Self tests (-fsanitize=address)
284+
run: ./v -cflags -fsanitize=address -silent test-self vlib

vlib/v/tests/builtin_maps/map_generic_call_test.v

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// vtest build: !sanitize-address-clang-without-gc
12
struct FooParams[K, V] {
23
k K
34
v V

vlib/v/tests/comptime/comptime_map_it_test.v

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// vtest build: !sanitize-address-clang-without-gc
12
type Any = []Any | f64 | int | map[string]Any | string
23

34
struct Arr {

0 commit comments

Comments
 (0)