ydb-platform / nbs

Network Block Store
Apache License 2.0
50 stars 15 forks source link

Fix unaligned memory access #1427

Closed drbasic closed 3 weeks ago

drbasic commented 3 weeks ago
cloud/blockstore/libs/common/ut <unittest> [tags: sb:MULTISLOT, sb:cores=4, sb:logs_ttl=3, sb:ssd, sb:ttl=3]
17 tests: 16 - GOOD, 1 - CRASHED
------ sole chunk ran 32 tests
[fail] TIOVectorTest::ShouldTrimVoidBuffers [tags: sb:MULTISLOT, sb:cores=4, sb:logs_ttl=3, sb:ssd, sb:ttl=3] [default-linux-x86_64-release-usan] (0.00s)
Test crashed (return code: 100)
/place/sandbox-data/tasks/7/5/2385368357/__FUSE/mount_path_79f41383-a47d-4688-851e-0f48ebe70820/cloud/blockstore/libs/common/iovector.cpp:183:9: runtime error: load of misaligned address 0x000003e17019 for type 'const TBigNumber' (aka 'const unsigned int'), which requires 4 byte alignment
0x000003e17019: note: pointer points here
 00 00 00  10 00 00 00 00 00 00 00  00 00 55 45 53 54 45 44  00 5d e1 03 00 00 00 00  30 00 00 00 00
              ^ 
    #0 0x1562d05 in NCloud::NBlockStore::IsAllZeroes /-S/cloud/blockstore/libs/common/iovector.cpp:183:9
    #1 0x1562d05 in NCloud::NBlockStore::TrimVoidBuffers(NCloud::NBlockStore::NProto::TIOVector&) /-S/cloud/blockstore/libs/common/iovector.cpp:127:13
    #2 0x9e4f28 in NCloud::NBlockStore::NTestSuiteTIOVectorTest::TTestCaseShouldTrimVoidBuffers::Execute_(NUnitTest::TTestContext&) /-S/cloud/blockstore/libs/common/iovector_ut.cpp:199:9
    #3 0x9e7716 in NCloud::NBlockStore::NTestSuiteTIOVectorTest::TCurrentTest::Execute()::'lambda'()::operator()() const /-S/cloud/blockstore/libs/common/iovector_ut.cpp:56:1
    #4 0xcad2ed in NUnitTest::TTestBase::Run(std::__y1::function<void ()>, TBasicString<char, std::__y1::char_traits<char> > const&, char const*, bool) /-S/library/cpp/testing/unittest/registar.cpp:374:18
    #5 0x9e6019 in NCloud::NBlockStore::NTestSuiteTIOVectorTest::TCurrentTest::Execute() /-S/cloud/blockstore/libs/common/iovector_ut.cpp:56:1
    #6 0xcadee8 in NUnitTest::TTestFactory::Execute() /-S/library/cpp/testing/unittest/registar.cpp:495:19
    #7 0xccc38c in NUnitTest::RunMain(int, char**) /-S/library/cpp/testing/unittest/utmain.cpp:877:44
    #8 0x7f18ded52082 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x24082) (BuildId: 1878e6b475720c7c51969e69ab2d276fae6d1dee)
    #9 0x9a27e8 in _start (http://proxy.sandbox.yandex-team.ru/6498653755/cloud/blockstore/libs/common/ut/cloud-blockstore-libs-common-ut+0x9a27e8) (BuildId: ed5616243e9361b5071b10a08d2178ebe96466b2)
SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior /place/sandbox-data/tasks/7/5/2385368357/__FUSE/mount_path_79f41383-a47d-4688-851e-0f48ebe70820/cloud/blockstore/libs/common/iovector.cpp:183:9 in
github-actions[bot] commented 3 weeks ago

[!NOTE] This is an automated comment that will be appended during run.

:green_circle: linux-x86_64-relwithdebinfo: all tests PASSED for commit 848b70de0e052cad563563e45cd6f1a7a7e0fde4. TESTS PASSED ERRORS FAILED SKIPPED MUTED?
5273 5273 0 0 0 0