Revert "fix: Add missing fp64 extensions in caps initialization"

This reverts commit 22a719d62f.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
This commit is contained in:
Compute-Runtime-Validation
2023-07-31 13:21:58 +02:00
committed by Compute-Runtime-Automation
parent 98fd9f5687
commit f4d05a8e6b
3 changed files with 2 additions and 42 deletions

View File

@@ -64,7 +64,6 @@ void ClDevice::setupFp64Flags() {
deviceInfo.doubleFpConfig = defaultFpFlags | CL_FP_SOFT_FLOAT;
deviceInfo.nativeVectorWidthDouble = 1;
deviceInfo.preferredVectorWidthDouble = 1;
deviceExtensions += "cl_khr_fp64 ";
}
} else {
deviceInfo.doubleFpConfig = 0;
@@ -427,13 +426,6 @@ void ClDevice::initializeCaps() {
initializeOsSpecificCaps();
getOpenclCFeaturesList(hwInfo, deviceInfo.openclCFeatures, getDevice().getCompilerProductHelper());
if (hwInfo.capabilityTable.ftrSupportsFP64Emulation &&
getDevice().getExecutionEnvironment()->isFP64EmulationEnabled()) {
cl_name_version openClCFeature;
openClCFeature.version = CL_MAKE_VERSION(3, 0, 0);
strcpy_s(openClCFeature.name, CL_NAME_VERSION_MAX_NAME_SIZE, "__opencl_c_fp64");
deviceInfo.openclCFeatures.push_back(openClCFeature);
}
}
void ClDevice::initializeExtensionsWithVersion() {

View File

@@ -123,10 +123,6 @@ struct DeviceGetCapsTest : public ::testing::Test {
EXPECT_STREQ("__opencl_c_integer_dot_product_input_4x8bit", (++openclCFeatureIterator)->name);
EXPECT_STREQ("__opencl_c_integer_dot_product_input_4x8bit_packed", (++openclCFeatureIterator)->name);
}
if (hwInfo.capabilityTable.ftrSupportsFP64Emulation &&
clDevice.getDevice().getExecutionEnvironment()->isFP64EmulationEnabled()) {
EXPECT_STREQ("__opencl_c_fp64", (++openclCFeatureIterator)->name);
}
EXPECT_EQ(clDevice.getDeviceInfo().openclCFeatures.end(), ++openclCFeatureIterator);
}
@@ -347,34 +343,6 @@ TEST_F(DeviceGetCapsTest, givenForceOclVersion12WhenCapsAreCreatedThenDeviceRepo
verifyOpenclCFeatures(*device);
}
TEST_F(DeviceGetCapsTest, givenForceOclVersion30AndFp64EmulationSupportedAndEnabledWhenCapsAreCreatedThenClKhrFp64AndOpenClCFp64ExtensionsAreReported) {
DebugManagerStateRestore dbgRestorer;
DebugManager.flags.ForceOCLVersion.set(30);
HardwareInfo hwInfo = *defaultHwInfo;
hwInfo.capabilityTable.ftrSupportsFP64Emulation = true;
auto executionEnvironment = MockDevice::prepareExecutionEnvironment(&hwInfo, 0u);
executionEnvironment->setFP64EmulationEnabled();
auto device = std::make_unique<MockClDevice>(MockDevice::createWithExecutionEnvironment<MockDevice>(&hwInfo, executionEnvironment, 0u));
device->executionEnvironment->setFP64EmulationEnabled();
const auto &caps = device->getDeviceInfo();
EXPECT_STREQ("OpenCL 3.0 NEO ", caps.clVersion);
EXPECT_STREQ("OpenCL C 1.2 ", caps.clCVersion);
EXPECT_EQ(CL_MAKE_VERSION(3u, 0u, 0u), caps.numericClVersion);
EXPECT_FALSE(device->ocl21FeaturesEnabled);
verifyOpenclCFeatures(*device);
bool openclCFp64Found = false;
for (auto &openclCFeature : device->getDeviceInfo().openclCFeatures) {
if (0 == strcmp("__opencl_c_fp64", openclCFeature.name)) {
openclCFp64Found = true;
break;
}
}
EXPECT_TRUE(openclCFp64Found);
EXPECT_TRUE(hasSubstr(caps.deviceExtensions, std::string("cl_khr_fp64")));
}
TEST_F(DeviceGetCapsTest, givenForceOCL21FeaturesSupportEnabledWhenCapsAreCreatedThenDeviceReportsSupportOfOcl21Features) {
DebugManagerStateRestore dbgRestorer;
DebugManager.flags.ForceOCLVersion.set(12);
@@ -1186,7 +1154,7 @@ TEST_F(DeviceGetCapsTest, givenFp64EmulationSupportWithFp64EmulationEnvVarSetWhe
auto &caps = pClDevice->getDeviceInfo();
std::string extensionString = pClDevice->getDeviceInfo().deviceExtensions;
EXPECT_NE(std::string::npos, extensionString.find(std::string("cl_khr_fp64")));
EXPECT_EQ(std::string::npos, extensionString.find(std::string("cl_khr_fp64")));
EXPECT_TRUE(isValueSet(caps.doubleFpConfig, CL_FP_SOFT_FLOAT));
cl_device_fp_config defaultFpFlags = static_cast<cl_device_fp_config>(CL_FP_ROUND_TO_NEAREST |