feature: support SPIR-V 1.4 and 1.5

Related-To: NEO-14312

Signed-off-by: Ben Ashbaugh <ben.ashbaugh@intel.com>
This commit is contained in:
Ben Ashbaugh
2025-05-30 17:51:43 +00:00
committed by Compute-Runtime-Automation
parent 64a80aef2e
commit 25d0daf754
5 changed files with 8 additions and 7 deletions

View File

@@ -284,7 +284,7 @@ TEST_F(clGetDeviceInfoTests, GivenClDeviceExtensionsParamWhenGettingDeviceInfoTh
}
}
TEST_F(clGetDeviceInfoTests, GivenClDeviceIlVersionParamWhenGettingDeviceInfoThenSpirv10To13IsReturned) {
TEST_F(clGetDeviceInfoTests, GivenClDeviceIlVersionParamWhenGettingDeviceInfoThenSpirv10To15IsReturned) {
size_t paramRetSize = 0;
cl_int retVal = clGetDeviceInfo(
@@ -306,7 +306,7 @@ TEST_F(clGetDeviceInfoTests, GivenClDeviceIlVersionParamWhenGettingDeviceInfoThe
nullptr);
EXPECT_EQ(CL_SUCCESS, retVal);
EXPECT_STREQ("SPIR-V_1.3 SPIR-V_1.2 SPIR-V_1.1 SPIR-V_1.0 ", paramValue.get());
EXPECT_STREQ("SPIR-V_1.5 SPIR-V_1.4 SPIR-V_1.3 SPIR-V_1.2 SPIR-V_1.1 SPIR-V_1.0 ", paramValue.get());
}
using matcherAtMostGen12lp = IsAtMostGfxCore<IGFX_GEN12LP_CORE>;

View File

@@ -175,7 +175,7 @@ TEST_F(DeviceGetCapsTest, WhenCreatingDeviceThenCapsArePopulatedCorrectly) {
EXPECT_NE(0u, caps.globalMemCacheSize);
EXPECT_LT(0u, sharedCaps.globalMemSize);
EXPECT_EQ(sharedCaps.maxMemAllocSize, caps.maxConstantBufferSize);
EXPECT_STREQ("SPIR-V_1.3 SPIR-V_1.2 SPIR-V_1.1 SPIR-V_1.0 ", sharedCaps.ilVersion);
EXPECT_STREQ("SPIR-V_1.5 SPIR-V_1.4 SPIR-V_1.3 SPIR-V_1.2 SPIR-V_1.1 SPIR-V_1.0 ", sharedCaps.ilVersion);
EXPECT_EQ(defaultHwInfo->capabilityTable.supportsIndependentForwardProgress, caps.independentForwardProgress);
EXPECT_EQ(static_cast<cl_bool>(CL_TRUE), caps.deviceAvailable);

View File

@@ -539,7 +539,7 @@ TEST(GetDeviceInfo, GivenPreferredInteropsWhenGettingDeviceInfoThenCorrectValueI
TEST(GetDeviceInfo, WhenQueryingIlsWithVersionThenProperValueIsReturned) {
auto device = std::make_unique<MockClDevice>(MockDevice::createWithNewExecutionEnvironment<MockDevice>(nullptr));
constexpr auto ilCount = 4;
constexpr auto ilCount = 6;
cl_name_version ilsWithVersion[ilCount];
size_t paramRetSize;
@@ -548,8 +548,9 @@ TEST(GetDeviceInfo, WhenQueryingIlsWithVersionThenProperValueIsReturned) {
EXPECT_EQ(CL_SUCCESS, retVal);
EXPECT_EQ(sizeof(cl_name_version) * ilCount, paramRetSize);
for (int i = 0; i < ilCount; i++) {
const unsigned minor = ilCount - i - 1;
EXPECT_EQ(1u, CL_VERSION_MAJOR(ilsWithVersion[i].version));
EXPECT_GT(4u, CL_VERSION_MINOR(ilsWithVersion[i].version));
EXPECT_EQ(minor, CL_VERSION_MINOR(ilsWithVersion[i].version));
EXPECT_EQ(0u, CL_VERSION_PATCH(ilsWithVersion[i].version));
EXPECT_STREQ("SPIR-V", ilsWithVersion[i].name);
}

View File

@@ -28,7 +28,7 @@
namespace NEO {
static const char *spirvWithVersion = "SPIR-V_1.3 SPIR-V_1.2 SPIR-V_1.1 SPIR-V_1.0 ";
static const char *spirvWithVersion = "SPIR-V_1.5 SPIR-V_1.4 SPIR-V_1.3 SPIR-V_1.2 SPIR-V_1.1 SPIR-V_1.0 ";
size_t Device::getMaxParameterSizeFromIGC() const {
CompilerInterface *compilerInterface = getCompilerInterface();

View File

@@ -509,7 +509,7 @@ TEST(DeviceGetCapsSimpleTest, givenVariousOclVersionsWhenCapsAreCreatedThenDevic
debugManager.flags.ForceOCLVersion.set(oclVersion);
auto device = std::unique_ptr<Device>(MockDevice::createWithNewExecutionEnvironment<MockDevice>(defaultHwInfo.get()));
const auto &caps = device->getDeviceInfo();
EXPECT_STREQ("SPIR-V_1.3 SPIR-V_1.2 SPIR-V_1.1 SPIR-V_1.0 ", caps.ilVersion);
EXPECT_STREQ("SPIR-V_1.5 SPIR-V_1.4 SPIR-V_1.3 SPIR-V_1.2 SPIR-V_1.1 SPIR-V_1.0 ", caps.ilVersion);
}
}