diff --git a/src/device.cpp b/src/device.cpp index 0678d6a1..cb6cf0d5 100644 --- a/src/device.cpp +++ b/src/device.cpp @@ -117,6 +117,9 @@ void cvk_device::init_vulkan_properties(VkInstance instance) { } void cvk_device::init_clvk_runtime_behaviors() { + m_clvk_properties = create_cvk_device_properties( + m_properties.deviceName, m_properties.vendorID, m_properties.deviceID, + m_properties.driverVersion, m_driver_properties.driverID); #define SET_DEVICE_PROPERTY(option, print) \ do { \ if (config.option.set) { \ @@ -1146,10 +1149,10 @@ bool cvk_device::init(VkInstance instance) { return false; } - init_clvk_runtime_behaviors(); - init_vulkan_properties(instance); + init_clvk_runtime_behaviors(); + init_driver_behaviors(); init_features(instance); diff --git a/src/device.hpp b/src/device.hpp index 0d2b0fd2..669a6570 100644 --- a/src/device.hpp +++ b/src/device.hpp @@ -67,10 +67,6 @@ struct cvk_device : public _cl_device_id, m_type = CL_DEVICE_TYPE_ACCELERATOR; break; } - - m_clvk_properties = create_cvk_device_properties( - m_properties.deviceName, m_properties.vendorID, - m_properties.deviceID); } static cvk_device* create(cvk_platform* platform, VkInstance instance, diff --git a/src/device_properties.cpp b/src/device_properties.cpp index c61c59de..8f7e4e67 100644 --- a/src/device_properties.cpp +++ b/src/device_properties.cpp @@ -252,9 +252,9 @@ static bool isNVIDIADevice(const uint32_t vendorID) { cvk_info_fn(#x); \ return std::make_unique(__VA_ARGS__); -std::unique_ptr -create_cvk_device_properties(const char* name, const uint32_t vendorID, - const uint32_t deviceID) { +std::unique_ptr create_cvk_device_properties( + const char* name, const uint32_t vendorID, const uint32_t deviceID, + const uint32_t driverVersion, const VkDriverId driverID) { if (isMaliDevice(name, vendorID)) { #ifdef __ANDROID__ // Find out which SoC this is. diff --git a/src/device_properties.hpp b/src/device_properties.hpp index e0ae8d96..c6abcd6e 100644 --- a/src/device_properties.hpp +++ b/src/device_properties.hpp @@ -72,6 +72,6 @@ struct cvk_device_properties { virtual ~cvk_device_properties() {} }; -std::unique_ptr -create_cvk_device_properties(const char* name, const uint32_t vendorID, - const uint32_t deviceID); +std::unique_ptr create_cvk_device_properties( + const char* name, const uint32_t vendorID, const uint32_t deviceID, + const uint32_t driverVersion, const VkDriverId driverId);