Skip to content

[BUG] Invalid memory read in cudf::io::inflate_kernel #13567

@davidwendt

Description

@davidwendt

The nightly memcheck tests found an invalid global device memory read in cudf::io::inflate_kernel

========= Invalid __global__ read of size 4 bytes
=========     at 0x11fa0 in void cudf::io::inflate_kernel<(int)128>(cudf::device_span<const cudf::device_span<const unsigned char, (unsigned long)18446744073709551615>, (unsigned long)18446744073709551615>, cudf::device_span<const cudf::device_span<unsigned char, (unsigned long)18446744073709551615>, (unsigned long)18446744073709551615>, cudf::device_span<cudf::io::compression_result, (unsigned long)18446744073709551615>, cudf::io::gzip_header_included)
=========     by thread (0,0,0) in block (2605,0,0)
=========     Address 0x7fba9f00654c is out of bounds
=========     and is inside the nearest allocation at 0x7fba9a000000 of size 83912015 bytes
=========     Saved host backtrace up to driver entry point at kernel launch time
=========     Host Frame: [0x304e32]
=========                in /usr/lib/x86_64-linux-gnu/libcuda.so.1
=========     Host Frame: [0x1488c]
=========                in /opt/conda/envs/test/bin/gtests/libcudf/../../../lib/libcudart.so.11.0
=========     Host Frame:cudaLaunchKernel [0x6c318]
=========                in /opt/conda/envs/test/bin/gtests/libcudf/../../../lib/libcudart.so.11.0
=========     Host Frame:cudf::io::gpuinflate(cudf::device_span<cudf::device_span<unsigned char const, 18446744073709551615ul> const, 18446744073709551615ul>, cudf::device_span<cudf::device_span<unsigned char, 18446744073709551615ul> const, 18446744073709551615ul>, cudf::device_span<cudf::io::compression_result, 18446744073709551615ul>, cudf::io::gzip_header_included, rmm::cuda_stream_view) [0x1429446]
=========                in /opt/conda/envs/test/bin/gtests/libcudf/../../../lib/libcudf.so
=========     Host Frame:cudf::io::text::(anonymous namespace)::bgzip_data_chunk_reader::decompression_blocks::decompress(rmm::cuda_stream_view) [0x15b3ad1]
=========                in /opt/conda/envs/test/bin/gtests/libcudf/../../../lib/libcudf.so
=========     Host Frame:cudf::io::text::(anonymous namespace)::bgzip_data_chunk_reader::get_next_chunk(unsigned long, rmm::cuda_stream_view) [0x15b44d8]
=========                in /opt/conda/envs/test/bin/gtests/libcudf/../../../lib/libcudf.so
...

The error can be recreated using the DATA_CHUNK_SOURCE_TEST as follows:

compute-sanitizer --tool memcheck gtests/DATA_CHUNK_SOURCE_TEST --gtest_filter=DataChunkSourceTest.BgzipSource --rmm_mode=cuda

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingcuIOcuIO issuelibcudfAffects libcudf (C++/CUDA) code.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions