diff options
author | Kristian Høgsberg Kristensen <[email protected]> | 2015-07-30 14:44:01 -0700 |
---|---|---|
committer | Kristian Høgsberg Kristensen <[email protected]> | 2015-08-24 13:45:39 -0700 |
commit | ee9788973f069152905d23f65c6742efe4362124 (patch) | |
tree | 4bb362f413fd79adaebc1e202a496f37a03ca2d4 /src/vulkan/anv_device.c | |
parent | c4e7ed91636769c0ca05a6360fe8c20b9176c1b1 (diff) |
vk: Implement multi-gen dispatch mechanism
Diffstat (limited to 'src/vulkan/anv_device.c')
-rw-r--r-- | src/vulkan/anv_device.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/vulkan/anv_device.c b/src/vulkan/anv_device.c index eaeae3b0a4f..4db344bf08c 100644 --- a/src/vulkan/anv_device.c +++ b/src/vulkan/anv_device.c @@ -532,6 +532,15 @@ VkResult anv_CreateDevice( assert(pCreateInfo->sType == VK_STRUCTURE_TYPE_DEVICE_CREATE_INFO); + switch (physical_device->info->gen) { + case 7: + driver_layer = &gen7_layer; + break; + case 8: + driver_layer = &gen8_layer; + break; + } + device = anv_instance_alloc(instance, sizeof(*device), 8, VK_SYSTEM_ALLOC_TYPE_API_OBJECT); if (!device) |