Merge c107e055cd3195a183e36deeda94ab4400f5f768 on remote branch

Change-Id: I7e1ef5360927e03d2a0b44c4fa43173d55994359
diff --git a/libc/Android.bp b/libc/Android.bp
index 80f2523..98e3594 100644
--- a/libc/Android.bp
+++ b/libc/Android.bp
@@ -39,6 +39,8 @@
         ":libc_sources_shared",
         "__cxa_thread_atexit_impl.cpp",
         "__libc_add_main_thread.cpp",
+        "__libc_init_scudo.cpp",
+        "__libc_set_target_sdk_version.cpp",
         "exit.c",
         "malloc_init.cpp",
     ],
diff --git a/libc/__libc_init_scudo.cpp b/libc/__libc_init_scudo.cpp
new file mode 100644
index 0000000..4891ab1
--- /dev/null
+++ b/libc/__libc_init_scudo.cpp
@@ -0,0 +1,18 @@
+/*
+ * Copyright (C) 2018 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+// Guest libc should not init scudo, as it was already done by host libc.
+void __libc_init_scudo() {}
diff --git a/libc/__libc_set_target_sdk_version.cpp b/libc/__libc_set_target_sdk_version.cpp
new file mode 100644
index 0000000..2ca07e3
--- /dev/null
+++ b/libc/__libc_set_target_sdk_version.cpp
@@ -0,0 +1,17 @@
+/*
+ * Copyright (C) 2021 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+void __libc_set_target_sdk_version(int) {}
diff --git a/libc/malloc_init.cpp b/libc/malloc_init.cpp
index e0fc52e..abe17a4 100644
--- a/libc/malloc_init.cpp
+++ b/libc/malloc_init.cpp
@@ -79,8 +79,10 @@
     native_bridge_aligned_alloc,
     native_bridge_malloc_info,
   };
+
   globals->malloc_dispatch_table = malloc_default_dispatch;
-  globals->current_dispatch_table = &globals->malloc_dispatch_table;
+  atomic_store(&globals->default_dispatch_table, &malloc_default_dispatch);
+  atomic_store(&globals->current_dispatch_table, &malloc_default_dispatch);
 }
 
 // Initializes memory allocation framework.
diff --git a/libvulkan/stubs_arm.cc b/libvulkan/stubs_arm.cc
index ffbd0cf..3766898 100644
--- a/libvulkan/stubs_arm.cc
+++ b/libvulkan/stubs_arm.cc
@@ -31,6 +31,7 @@
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkBindImageMemory2);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdBeginQuery);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdBeginRenderPass);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdBeginRenderPass2);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdBindDescriptorSets);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdBindIndexBuffer);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdBindPipeline);
@@ -50,12 +51,16 @@
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdDraw);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdDrawIndexed);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdDrawIndexedIndirect);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdDrawIndexedIndirectCount);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdDrawIndirect);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdDrawIndirectCount);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdEndQuery);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdEndRenderPass);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdEndRenderPass2);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdExecuteCommands);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdFillBuffer);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdNextSubpass);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdNextSubpass2);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdPipelineBarrier);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdPushConstants);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdResetEvent);
@@ -95,6 +100,7 @@
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCreatePipelineLayout);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCreateQueryPool);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCreateRenderPass);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCreateRenderPass2);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCreateSampler);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCreateSamplerYcbcrConversion);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCreateSemaphore);
@@ -138,13 +144,16 @@
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkFreeDescriptorSets);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkFreeMemory);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetAndroidHardwareBufferPropertiesANDROID);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetBufferDeviceAddress);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetBufferMemoryRequirements);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetBufferMemoryRequirements2);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetBufferOpaqueCaptureAddress);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDescriptorSetLayoutSupport);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceGroupPeerMemoryFeatures);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceGroupPresentCapabilitiesKHR);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceGroupSurfacePresentModesKHR);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceMemoryCommitment);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceMemoryOpaqueCaptureAddress);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceProcAddr);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceQueue);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceQueue2);
@@ -182,6 +191,7 @@
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetPipelineCacheData);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetQueryPoolResults);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetRenderAreaGranularity);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetSemaphoreCounterValue);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetSwapchainImagesKHR);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkInvalidateMappedMemoryRanges);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkMapMemory);
@@ -195,12 +205,15 @@
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkResetDescriptorPool);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkResetEvent);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkResetFences);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkResetQueryPool);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkSetEvent);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkSignalSemaphore);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkTrimCommandPool);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkUnmapMemory);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkUpdateDescriptorSetWithTemplate);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkUpdateDescriptorSets);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkWaitForFences);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkWaitSemaphores);
 
 static void __attribute__((constructor(0))) init_stub_library() {
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", android_convertGralloc0To1Usage);
@@ -217,6 +230,7 @@
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkBindImageMemory2);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdBeginQuery);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdBeginRenderPass);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdBeginRenderPass2);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdBindDescriptorSets);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdBindIndexBuffer);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdBindPipeline);
@@ -236,12 +250,16 @@
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdDraw);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdDrawIndexed);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdDrawIndexedIndirect);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdDrawIndexedIndirectCount);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdDrawIndirect);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdDrawIndirectCount);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdEndQuery);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdEndRenderPass);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdEndRenderPass2);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdExecuteCommands);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdFillBuffer);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdNextSubpass);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdNextSubpass2);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdPipelineBarrier);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdPushConstants);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdResetEvent);
@@ -281,6 +299,7 @@
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCreatePipelineLayout);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCreateQueryPool);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCreateRenderPass);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCreateRenderPass2);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCreateSampler);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCreateSamplerYcbcrConversion);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCreateSemaphore);
@@ -324,13 +343,16 @@
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkFreeDescriptorSets);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkFreeMemory);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetAndroidHardwareBufferPropertiesANDROID);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetBufferDeviceAddress);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetBufferMemoryRequirements);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetBufferMemoryRequirements2);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetBufferOpaqueCaptureAddress);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDescriptorSetLayoutSupport);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceGroupPeerMemoryFeatures);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceGroupPresentCapabilitiesKHR);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceGroupSurfacePresentModesKHR);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceMemoryCommitment);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceMemoryOpaqueCaptureAddress);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceProcAddr);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceQueue);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceQueue2);
@@ -368,6 +390,7 @@
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetPipelineCacheData);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetQueryPoolResults);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetRenderAreaGranularity);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetSemaphoreCounterValue);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetSwapchainImagesKHR);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkInvalidateMappedMemoryRanges);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkMapMemory);
@@ -381,11 +404,14 @@
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkResetDescriptorPool);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkResetEvent);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkResetFences);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkResetQueryPool);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkSetEvent);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkSignalSemaphore);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkTrimCommandPool);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkUnmapMemory);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkUpdateDescriptorSetWithTemplate);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkUpdateDescriptorSets);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkWaitForFences);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkWaitSemaphores);
 }
 // clang-format on
diff --git a/libvulkan/stubs_arm64.cc b/libvulkan/stubs_arm64.cc
index ffbd0cf..3766898 100644
--- a/libvulkan/stubs_arm64.cc
+++ b/libvulkan/stubs_arm64.cc
@@ -31,6 +31,7 @@
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkBindImageMemory2);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdBeginQuery);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdBeginRenderPass);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdBeginRenderPass2);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdBindDescriptorSets);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdBindIndexBuffer);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdBindPipeline);
@@ -50,12 +51,16 @@
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdDraw);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdDrawIndexed);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdDrawIndexedIndirect);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdDrawIndexedIndirectCount);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdDrawIndirect);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdDrawIndirectCount);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdEndQuery);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdEndRenderPass);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdEndRenderPass2);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdExecuteCommands);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdFillBuffer);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdNextSubpass);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdNextSubpass2);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdPipelineBarrier);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdPushConstants);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCmdResetEvent);
@@ -95,6 +100,7 @@
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCreatePipelineLayout);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCreateQueryPool);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCreateRenderPass);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCreateRenderPass2);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCreateSampler);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCreateSamplerYcbcrConversion);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkCreateSemaphore);
@@ -138,13 +144,16 @@
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkFreeDescriptorSets);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkFreeMemory);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetAndroidHardwareBufferPropertiesANDROID);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetBufferDeviceAddress);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetBufferMemoryRequirements);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetBufferMemoryRequirements2);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetBufferOpaqueCaptureAddress);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDescriptorSetLayoutSupport);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceGroupPeerMemoryFeatures);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceGroupPresentCapabilitiesKHR);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceGroupSurfacePresentModesKHR);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceMemoryCommitment);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceMemoryOpaqueCaptureAddress);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceProcAddr);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceQueue);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetDeviceQueue2);
@@ -182,6 +191,7 @@
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetPipelineCacheData);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetQueryPoolResults);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetRenderAreaGranularity);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetSemaphoreCounterValue);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkGetSwapchainImagesKHR);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkInvalidateMappedMemoryRanges);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkMapMemory);
@@ -195,12 +205,15 @@
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkResetDescriptorPool);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkResetEvent);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkResetFences);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkResetQueryPool);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkSetEvent);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkSignalSemaphore);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkTrimCommandPool);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkUnmapMemory);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkUpdateDescriptorSetWithTemplate);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkUpdateDescriptorSets);
 DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkWaitForFences);
+DEFINE_INTERCEPTABLE_STUB_FUNCTION(vkWaitSemaphores);
 
 static void __attribute__((constructor(0))) init_stub_library() {
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", android_convertGralloc0To1Usage);
@@ -217,6 +230,7 @@
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkBindImageMemory2);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdBeginQuery);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdBeginRenderPass);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdBeginRenderPass2);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdBindDescriptorSets);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdBindIndexBuffer);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdBindPipeline);
@@ -236,12 +250,16 @@
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdDraw);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdDrawIndexed);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdDrawIndexedIndirect);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdDrawIndexedIndirectCount);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdDrawIndirect);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdDrawIndirectCount);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdEndQuery);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdEndRenderPass);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdEndRenderPass2);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdExecuteCommands);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdFillBuffer);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdNextSubpass);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdNextSubpass2);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdPipelineBarrier);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdPushConstants);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCmdResetEvent);
@@ -281,6 +299,7 @@
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCreatePipelineLayout);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCreateQueryPool);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCreateRenderPass);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCreateRenderPass2);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCreateSampler);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCreateSamplerYcbcrConversion);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkCreateSemaphore);
@@ -324,13 +343,16 @@
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkFreeDescriptorSets);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkFreeMemory);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetAndroidHardwareBufferPropertiesANDROID);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetBufferDeviceAddress);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetBufferMemoryRequirements);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetBufferMemoryRequirements2);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetBufferOpaqueCaptureAddress);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDescriptorSetLayoutSupport);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceGroupPeerMemoryFeatures);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceGroupPresentCapabilitiesKHR);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceGroupSurfacePresentModesKHR);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceMemoryCommitment);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceMemoryOpaqueCaptureAddress);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceProcAddr);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceQueue);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetDeviceQueue2);
@@ -368,6 +390,7 @@
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetPipelineCacheData);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetQueryPoolResults);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetRenderAreaGranularity);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetSemaphoreCounterValue);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkGetSwapchainImagesKHR);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkInvalidateMappedMemoryRanges);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkMapMemory);
@@ -381,11 +404,14 @@
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkResetDescriptorPool);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkResetEvent);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkResetFences);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkResetQueryPool);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkSetEvent);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkSignalSemaphore);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkTrimCommandPool);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkUnmapMemory);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkUpdateDescriptorSetWithTemplate);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkUpdateDescriptorSets);
   INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkWaitForFences);
+  INIT_INTERCEPTABLE_STUB_FUNCTION("libvulkan.so", vkWaitSemaphores);
 }
 // clang-format on