Skip to content

Segfault while running tests against ASAN build (Clang-16) #321

@ylobankov

Description

@ylobankov

Tarantool

Tarantool 3.0.0-alpha1-66-g10870343a
Target: Linux-x86_64-RelWithDebInfo
Build options: cmake . -DCMAKE_INSTALL_PREFIX=/usr/local -DENABLE_BACKTRACE=TRUE
Compiler: Clang-16.0.6
C_FLAGS: -fexceptions -funwind-tables -fasynchronous-unwind-tables -fno-common -msse2 -fsanitize=fuzzer-no-link -fsanitize=address -fsanitize-blacklist=/tarantool/asan/asan.supp  -fmacro-prefix-map=/tarantool=. -std=c11 -Wall -Wextra -fsanitize=alignment,bool,bounds,builtin,enum,float-cast-overflow,float-divide-by-zero,function,integer-divide-by-zero,return,shift,unreachable,vla-bound -fno-sanitize-recover=alignment,bool,bounds,builtin,enum,float-cast-overflow,float-divide-by-zero,function,integer-divide-by-zero,return,shift,unreachable,vla-bound -Wno-gnu-alignof-expression -Wno-cast-function-type -Werror
CXX_FLAGS: -fexceptions -funwind-tables -fasynchronous-unwind-tables -fno-common -msse2 -fsanitize=fuzzer-no-link -fsanitize=address -fsanitize-blacklist=/tarantool/asan/asan.supp  -fmacro-prefix-map=/tarantool=. -std=c++11 -Wall -Wextra -fsanitize=alignment,bool,bounds,builtin,enum,float-cast-overflow,float-divide-by-zero,function,integer-divide-by-zero,return,shift,unreachable,vla-bound -fno-sanitize-recover=alignment,bool,bounds,builtin,enum,float-cast-overflow,float-divide-by-zero,function,integer-divide-by-zero,return,shift,unreachable,vla-bound -Wno-invalid-offsetof -Wno-gnu-alignof-expression -Wno-cast-function-type -Werror

Steps to reproduce

docker run -it --rm tarantool/testing:ubuntu-jammy-clang16
git clone https://github.com/tarantool/tarantool.git
cd tarantool && git submodule update --recursive --init --jobs $(nproc)

Open .test.mk file and remove run-luajit-test target from L112. Save and exit.

CC=clang-16 CXX=clang++-16 TEST_RUN_EXTRA_PARAMS=app/fiber.test.lua make -f .test.mk test-release-asan

The command above runs one test only. If you want to get all failures, remove TEST_RUN_EXTRA_PARAMS=app/fiber.test.lua from the command.

Expected result: Test passed.

Actual result:

======================================================================================
WORKR TEST                                            PARAMS          RESULT
---------------------------------------------------------------------------------
[001]
[001] [Instance "app"] Failed to start: Broken tarantool console handshake
[001]
[001] [test-run server "app"] Last 15 lines of the log file /tmp/t/001_app/app.log:
[001]   fs       0x0                0
[001]   cr2      0x7f9294552f60     140267530563424
[001]   err      0x4                4
[001]   oldmask  0x0                0
[001]   trapno   0xe                14
[001] Current time: 1691493315
[001] Please file a bug at https://github.com/tarantool/tarantool/issues
[001] Attempting backtrace... Note: since the server has already crashed,
[001] this may fail as well
[001] #1  0x55e5a1f1581f in crash_collect+575
[001] #2  0x55e5a1f155a8 in crash_signal_cb+424
[001] #3  0x7f9298145520 in __sigaction+80
[001] #4  0x55e5a1f260f9 in fiber_yield+1113
[001] #5  0x55e5a1f2d973 in fiber_loop+2259
[001] #6  0x55e5a2860273 in coro_init+307
[001]
[001] [Instance "app"] Failed to start: Broken tarantool console handshake
---------------------------------------------------------------------------------

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions