Juan Manuel Martinez Caamaño a276624b2e
[SPIRV][SPIRVPrepareGlobals] Map AMD's dynamic LDS 0-element globals to arrays with UINT32_MAX elements (#166952)
In HIP, dynamic LDS variables are represented using `0-element` global
arrays in the `__shared__` language address-space.

```cpp
  extern __shared__ int LDS[];
```

These are not representable in SPIRV directly.

To represent them, for AMD, we use an array with `UINT32_MAX`-elements.
These are reverse translated to 0-element arrays later in AMD's SPIRV
runtime pipeline (in
[SPIRVReader.cpp](8cb74e264d/lib/SPIRV/SPIRVReader.cpp (L358))).
2025-11-12 10:44:55 +00:00
..