diff --git a/rocclr/runtime/device/gpu/gpudevice.cpp b/rocclr/runtime/device/gpu/gpudevice.cpp index dbc07c8bef..21779155e3 100644 --- a/rocclr/runtime/device/gpu/gpudevice.cpp +++ b/rocclr/runtime/device/gpu/gpudevice.cpp @@ -1623,6 +1623,12 @@ bool Device::createSampler(const amd::Sampler& owner, device::Sampler** sampler) return false; } *sampler = gpuSampler; + } else { + //! Currently allocate the base device class for AMDIL path + *sampler = new device::Sampler(); + if (*sampler == nullptr) { + return false; + } } return true; }