Skip to content

Conversation

uditagarwal97
Copy link
Contributor

@uditagarwal97 uditagarwal97 commented Sep 4, 2025

Problem
There can be race during image decompression. Consider the case when one thread is reading the decompressed buffer while another thread modifies it. This can lead to invalid SPIRV errors emitted by IGC.

Proposed solution
Use std::call_once to ensure that only one thread does the decompression of an image.

@uditagarwal97 uditagarwal97 force-pushed the private/udit/zstd_multithreaded_decomp branch from 52cb519 to 0d8ecf3 Compare September 4, 2025 23:29
@uditagarwal97 uditagarwal97 marked this pull request as ready for review September 5, 2025 15:44
@uditagarwal97
Copy link
Contributor Author

Failed Tests (1):
  SYCL :: KernelCompiler/sycl_device_globals.cpp

Failure on CUDA is unrelated and already reported in #19965

@uditagarwal97 uditagarwal97 merged commit e86363f into sycl Sep 5, 2025
26 of 27 checks passed
@uditagarwal97 uditagarwal97 deleted the private/udit/zstd_multithreaded_decomp branch September 5, 2025 16:15
AlexeySachkov pushed a commit to AlexeySachkov/llvm that referenced this pull request Sep 18, 2025
**Problem**
There can be race during image decompression. Consider the case when one
thread is reading the decompressed buffer while another thread modifies
it. This can lead to invalid SPIRV errors emitted by IGC.

**Proposed solution**
Use `std::call_once` to ensure that only one thread does the
decompression of an image.
AlexeySachkov added a commit that referenced this pull request Sep 18, 2025
This is a cherry-pick of #19981

**Problem**
There can be race during image decompression. Consider the case when one
thread is reading the decompressed buffer while another thread modifies
it. This can lead to invalid SPIRV errors emitted by IGC.

**Proposed solution**
Use `std::call_once` to ensure that only one thread does the
decompression of an image.

Patch-by: Udit Kumar Agarwal <udit.agarwal@intel.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants