loader: gh888 Add KHR/EXT extensions in vulkan.h

Add the KHR_display_swapchain device extension to the loader
and the core_validation layers.  This fulfills the work required in
JIRA LOAD-7 and gh 90.

Add debug_marker to the extension list.

Change-Id: I1fb70e5d44bc8c1f70fd6d1cfbd106a155081b25
diff --git a/loader/LoaderAndLayerInterface.md b/loader/LoaderAndLayerInterface.md
index c3abd9f..8bb07d5 100644
--- a/loader/LoaderAndLayerInterface.md
+++ b/loader/LoaderAndLayerInterface.md
@@ -333,8 +333,6 @@
 device.  Thus, the overwhelming majority of extensions will be device extensions rather than
 instance extensions.
 
-<br/>
-
 
 ## Vulkan Installable Client Driver interface with the loader ##
 
diff --git a/loader/table_ops.h b/loader/table_ops.h
index 5a9abf1..2b4d6d4 100644
--- a/loader/table_ops.h
+++ b/loader/table_ops.h
@@ -276,6 +276,18 @@
     table->GetMemoryWin32HandleNV =
         (PFN_vkGetMemoryWin32HandleNV)gpa(dev, "vkGetMemoryWin32HandleNV");
 #endif // VK_USE_PLATFORM_WIN32_KHR
+    table->CreateSharedSwapchainsKHR =
+        (PFN_vkCreateSharedSwapchainsKHR)gpa(dev, "vkCreateSharedSwapchainsKHR");
+    table->DebugMarkerSetObjectTagEXT =
+        (PFN_vkDebugMarkerSetObjectTagEXT)gpa(dev, "vkDebugMarkerSetObjectTagEXT");
+    table->DebugMarkerSetObjectNameEXT =
+        (PFN_vkDebugMarkerSetObjectNameEXT)gpa(dev, "vkDebugMarkerSetObjectNameEXT");
+    table->CmdDebugMarkerBeginEXT =
+        (PFN_vkCmdDebugMarkerBeginEXT)gpa(dev, "vkCmdDebugMarkerBeginEXT");
+    table->CmdDebugMarkerEndEXT =
+        (PFN_vkCmdDebugMarkerEndEXT)gpa(dev, "vkCmdDebugMarkerEndEXT");
+    table->CmdDebugMarkerInsertEXT =
+        (PFN_vkCmdDebugMarkerInsertEXT)gpa(dev, "vkCmdDebugMarkerInsertEXT");
 }
 
 static inline void *
diff --git a/loader/wsi.c b/loader/wsi.c
index 539dbac..10c5260 100644
--- a/loader/wsi.c
+++ b/loader/wsi.c
@@ -1262,6 +1262,18 @@
     return VK_SUCCESS;
 }
 
+// This is the trampoline entrypoint
+// for CreateSharedSwapchainsKHR
+LOADER_EXPORT VKAPI_ATTR VkResult VKAPI_CALL vkCreateSharedSwapchainsKHR(
+    VkDevice device, uint32_t swapchainCount,
+    const VkSwapchainCreateInfoKHR *pCreateInfos,
+    const VkAllocationCallbacks *pAllocator, VkSwapchainKHR *pSwapchains) {
+    const VkLayerDispatchTable *disp;
+    disp = loader_get_dispatch(device);
+    return disp->CreateSharedSwapchainsKHR(
+        device, swapchainCount, pCreateInfos, pAllocator, pSwapchains);
+}
+
 bool wsi_swapchain_instance_gpa(struct loader_instance *ptr_instance,
                                 const char *name, void **addr) {
     *addr = NULL;
@@ -1458,5 +1470,12 @@
                     : NULL;
         return true;
     }
+
+    // Functions for KHR_display_swapchain extension:
+    if (!strcmp("vkCreateSharedSwapchainsKHR", name)) {
+        *addr = (void *)vkCreateSharedSwapchainsKHR;
+        return true;
+    }
+
     return false;
 }