if (mem_barrier->oldLayout == VK_IMAGE_LAYOUT_UNDEFINED) {
// TODO: Set memory invalid which is in mem_tracker currently
} else if (node.layout != mem_barrier->oldLayout) {
- skip |=
- log_msg(core_validation::GetReportData(device_data), VK_DEBUG_REPORT_ERROR_BIT_EXT,
- VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, HandleToUint64(pCB->commandBuffer), __LINE__,
- DRAWSTATE_INVALID_IMAGE_LAYOUT, "DS",
- "For image 0x%" PRIxLEAST64 " you cannot transition the layout of aspect %d from %s when current layout is %s.",
- HandleToUint64(mem_barrier->image), aspect, string_VkImageLayout(mem_barrier->oldLayout),
- string_VkImageLayout(node.layout));
+ skip |= log_msg(core_validation::GetReportData(device_data), VK_DEBUG_REPORT_ERROR_BIT_EXT,
+ VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, HandleToUint64(pCB->commandBuffer), __LINE__,
+ DRAWSTATE_INVALID_IMAGE_LAYOUT, "DS",
+ "For image 0x%" PRIx64 " you cannot transition the layout of aspect %d from %s when current layout is %s.",
+ HandleToUint64(mem_barrier->image), aspect, string_VkImageLayout(mem_barrier->oldLayout),
+ string_VkImageLayout(node.layout));
}
return skip;
}
log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
HandleToUint64(img_barrier->image), __LINE__, msg_code, "DS",
"%s: Image barrier 0x%p %sLayout=%s is not compatible with image 0x%" PRIx64 " usage flags 0x%" PRIx32 ". %s",
- func_name, img_barrier, ((new_not_old) ? "new" : "old"), string_VkImageLayout(layout),
- HandleToUint64(img_barrier->image), usage_flags, validation_error_map[msg_code]);
+ func_name, static_cast<const void *>(img_barrier), ((new_not_old) ? "new" : "old"),
+ string_VkImageLayout(layout), HandleToUint64(img_barrier->image), usage_flags, validation_error_map[msg_code]);
}
return skip;
}
skip |= log_msg(
core_validation::GetReportData(device_data), VK_DEBUG_REPORT_ERROR_BIT_EXT,
VK_DEBUG_REPORT_OBJECT_TYPE_UNKNOWN_EXT, 0, __LINE__, 0, "DS",
- "Attempting to transition shared presentable image 0x%" PRIxLEAST64
+ "Attempting to transition shared presentable image 0x%" PRIx64
" from layout %s to layout %s, but image has already been presented and cannot have its layout transitioned.",
- reinterpret_cast<const uint64_t &>(img_barrier->image), string_VkImageLayout(img_barrier->oldLayout),
+ HandleToUint64(img_barrier->image), string_VkImageLayout(img_barrier->oldLayout),
string_VkImageLayout(img_barrier->newLayout));
}
}
auto const aspect_mask = img_barrier->subresourceRange.aspectMask;
auto const ds_mask = VK_IMAGE_ASPECT_DEPTH_BIT | VK_IMAGE_ASPECT_STENCIL_BIT;
if ((aspect_mask & ds_mask) != (ds_mask)) {
- skip |=
- log_msg(core_validation::GetReportData(device_data), VK_DEBUG_REPORT_ERROR_BIT_EXT,
- VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT, HandleToUint64(img_barrier->image), __LINE__,
- VALIDATION_ERROR_0a00096e, "DS",
- "%s: Image barrier 0x%p references image 0x%" PRIx64
- " of format %s that must have the depth and stencil aspects set, but its "
- "aspectMask is 0x%" PRIx32 ". %s",
- func_name, img_barrier, HandleToUint64(img_barrier->image), string_VkFormat(image_create_info->format),
- aspect_mask, validation_error_map[VALIDATION_ERROR_0a00096e]);
+ skip |= log_msg(
+ core_validation::GetReportData(device_data), VK_DEBUG_REPORT_ERROR_BIT_EXT,
+ VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT, HandleToUint64(img_barrier->image), __LINE__, VALIDATION_ERROR_0a00096e,
+ "DS", "%s: Image barrier 0x%p references image 0x%" PRIx64
+ " of format %s that must have the depth and stencil aspects set, but its "
+ "aspectMask is 0x%" PRIx32 ". %s",
+ func_name, static_cast<const void *>(img_barrier), HandleToUint64(img_barrier->image),
+ string_VkFormat(image_create_info->format), aspect_mask, validation_error_map[VALIDATION_ERROR_0a00096e]);
}
}
uint32_t level_count = ResolveRemainingLevels(&img_barrier->subresourceRange, image_create_info->mipLevels);
if (node.layout != explicit_layout) {
*error = true;
// TODO: Improve log message in the next pass
- skip |= log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
- HandleToUint64(cb_node->commandBuffer), __LINE__, DRAWSTATE_INVALID_IMAGE_LAYOUT, "DS",
- "%s: Cannot use image 0x%" PRIxLEAST64
- " with specific layout %s that doesn't match the actual current layout %s.",
- caller, HandleToUint64(image), string_VkImageLayout(explicit_layout),
- string_VkImageLayout(node.layout));
+ skip |= log_msg(
+ report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
+ HandleToUint64(cb_node->commandBuffer), __LINE__, DRAWSTATE_INVALID_IMAGE_LAYOUT, "DS",
+ "%s: Cannot use image 0x%" PRIx64 " with specific layout %s that doesn't match the actual current layout %s.",
+ caller, HandleToUint64(image), string_VkImageLayout(explicit_layout), string_VkImageLayout(node.layout));
}
}
}
skip |= log_msg(report_data, VK_DEBUG_REPORT_PERFORMANCE_WARNING_BIT_EXT,
VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, HandleToUint64(cb_node->commandBuffer), __LINE__,
DRAWSTATE_INVALID_IMAGE_LAYOUT, "DS",
- "%s: For optimal performance image 0x%" PRIxLEAST64 " layout should be %s instead of GENERAL.",
- caller, HandleToUint64(image), string_VkImageLayout(optimal_layout));
+ "%s: For optimal performance image 0x%" PRIx64 " layout should be %s instead of GENERAL.", caller,
+ HandleToUint64(image), string_VkImageLayout(optimal_layout));
}
} else if (GetDeviceExtensions(device_data)->vk_khr_shared_presentable_image) {
if (image_state->shared_presentable) {
*error = true;
skip |= log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(cb_node->commandBuffer), __LINE__, msg_code, "DS",
- "%s: Layout for image 0x%" PRIxLEAST64 " is %s but can only be %s or VK_IMAGE_LAYOUT_GENERAL. %s",
- caller, HandleToUint64(image), string_VkImageLayout(explicit_layout),
- string_VkImageLayout(optimal_layout), validation_error_map[msg_code]);
+ "%s: Layout for image 0x%" PRIx64 " is %s but can only be %s or VK_IMAGE_LAYOUT_GENERAL. %s", caller,
+ HandleToUint64(image), string_VkImageLayout(explicit_layout), string_VkImageLayout(optimal_layout),
+ validation_error_map[msg_code]);
}
}
return skip;
if ((0 != image_copy.srcOffset.y) || (1 != image_copy.extent.height)) {
skip |=
log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(src_state->image), __LINE__, VALIDATION_ERROR_09c00124, "IMAGE",
+ HandleToUint64(src_state->image), __LINE__, VALIDATION_ERROR_09c00124, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] srcOffset.y is %d and extent.height is %d. For 1D images these must "
"be 0 and 1, respectively. %s",
i, image_copy.srcOffset.y, image_copy.extent.height, validation_error_map[VALIDATION_ERROR_09c00124]);
if ((0 != image_copy.srcOffset.z) || (1 != image_copy.extent.depth)) {
skip |=
log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(src_state->image), __LINE__, VALIDATION_ERROR_09c00128, "IMAGE",
+ HandleToUint64(src_state->image), __LINE__, VALIDATION_ERROR_09c00128, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] srcOffset.z is %d and extent.depth is %d. For 1D and 2D images "
"these must be 0 and 1, respectively. %s",
i, image_copy.srcOffset.z, image_copy.extent.depth, validation_error_map[VALIDATION_ERROR_09c00128]);
if ((0 != image_copy.srcSubresource.baseArrayLayer) || (1 != image_copy.srcSubresource.layerCount)) {
skip |=
log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(src_state->image), __LINE__, VALIDATION_ERROR_09c0011a, "IMAGE",
+ HandleToUint64(src_state->image), __LINE__, VALIDATION_ERROR_09c0011a, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] srcSubresource.baseArrayLayer is %d and srcSubresource.layerCount "
"is %d. For VK_IMAGE_TYPE_3D images these must be 0 and 1, respectively. %s",
i, image_copy.srcSubresource.baseArrayLayer, image_copy.srcSubresource.layerCount,
} else { // Pre maint 1
if (src_state->createInfo.imageType == VK_IMAGE_TYPE_3D || dst_state->createInfo.imageType == VK_IMAGE_TYPE_3D) {
if ((0 != image_copy.srcSubresource.baseArrayLayer) || (1 != image_copy.srcSubresource.layerCount)) {
- skip |=
- log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(src_state->image), __LINE__, VALIDATION_ERROR_09c0011a, "IMAGE",
- "vkCmdCopyImage(): pRegion[%d] srcSubresource.baseArrayLayer is %d and "
- "srcSubresource.layerCount is %d. For copies with either source or dest of type "
- "VK_IMAGE_TYPE_3D, these must be 0 and 1, respectively. %s",
- i, image_copy.srcSubresource.baseArrayLayer, image_copy.srcSubresource.layerCount,
- validation_error_map[VALIDATION_ERROR_09c0011a]);
+ skip |= log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
+ HandleToUint64(src_state->image), __LINE__, VALIDATION_ERROR_09c0011a, "IMAGE",
+ "vkCmdCopyImage(): pRegion[%d] srcSubresource.baseArrayLayer is %d and "
+ "srcSubresource.layerCount is %d. For copies with either source or dest of type "
+ "VK_IMAGE_TYPE_3D, these must be 0 and 1, respectively. %s",
+ i, image_copy.srcSubresource.baseArrayLayer, image_copy.srcSubresource.layerCount,
+ validation_error_map[VALIDATION_ERROR_09c0011a]);
}
}
}
if ((image_copy.srcSubresource.baseArrayLayer >= src_state->createInfo.arrayLayers) ||
(image_copy.srcSubresource.baseArrayLayer + image_copy.srcSubresource.layerCount > src_state->createInfo.arrayLayers)) {
skip |= log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(src_state->image), __LINE__, VALIDATION_ERROR_09c0012a, "IMAGE",
+ HandleToUint64(src_state->image), __LINE__, VALIDATION_ERROR_09c0012a, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] srcSubresource.baseArrayLayer (%d) must be less than the source image's "
"arrayLayers (%d), and the sum of baseArrayLayer and srcSubresource.layerCount (%d) must be less than "
"or equal to the source image's arrayLayers. %s",
(SafeModulo(image_copy.srcOffset.y, block_size.height) != 0) ||
(SafeModulo(image_copy.srcOffset.z, block_size.depth) != 0)) {
skip |= log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(src_state->image), __LINE__, VALIDATION_ERROR_09c0013a, "IMAGE",
+ HandleToUint64(src_state->image), __LINE__, VALIDATION_ERROR_09c0013a, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] srcOffset (%d, %d) must be multiples of the compressed image's "
"texel width & height (%d, %d). %s.",
i, image_copy.srcOffset.x, image_copy.srcOffset.y, block_size.width, block_size.height,
(adj_extent.width + image_copy.srcOffset.x != mip_extent.width)) {
skip |=
log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(src_state->image), __LINE__, VALIDATION_ERROR_09c0013c, "IMAGE",
+ HandleToUint64(src_state->image), __LINE__, VALIDATION_ERROR_09c0013c, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] extent width (%d) must be a multiple of the compressed texture block "
"width (%d), or when added to srcOffset.x (%d) must equal the image subresource width (%d). %s.",
i, adj_extent.width, block_size.width, image_copy.srcOffset.x, mip_extent.width,
(adj_extent.height + image_copy.srcOffset.y != mip_extent.height)) {
skip |=
log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(src_state->image), __LINE__, VALIDATION_ERROR_09c0013e, "IMAGE",
+ HandleToUint64(src_state->image), __LINE__, VALIDATION_ERROR_09c0013e, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] extent height (%d) must be a multiple of the compressed texture block "
"height (%d), or when added to srcOffset.y (%d) must equal the image subresource height (%d). %s.",
i, adj_extent.height, block_size.height, image_copy.srcOffset.y, mip_extent.height,
if ((SafeModulo(copy_depth, block_size.depth) != 0) && (copy_depth + image_copy.srcOffset.z != mip_extent.depth)) {
skip |=
log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(src_state->image), __LINE__, VALIDATION_ERROR_09c00140, "IMAGE",
+ HandleToUint64(src_state->image), __LINE__, VALIDATION_ERROR_09c00140, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] extent width (%d) must be a multiple of the compressed texture block "
"depth (%d), or when added to srcOffset.z (%d) must equal the image subresource depth (%d). %s.",
i, image_copy.extent.depth, block_size.depth, image_copy.srcOffset.z, mip_extent.depth,
if ((0 != image_copy.dstOffset.y) || (1 != image_copy.extent.height)) {
skip |=
log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(dst_state->image), __LINE__, VALIDATION_ERROR_09c00130, "IMAGE",
+ HandleToUint64(dst_state->image), __LINE__, VALIDATION_ERROR_09c00130, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] dstOffset.y is %d and extent.height is %d. For 1D images these must "
"be 0 and 1, respectively. %s",
i, image_copy.dstOffset.y, image_copy.extent.height, validation_error_map[VALIDATION_ERROR_09c00130]);
if ((0 != image_copy.dstOffset.z) || (1 != image_copy.extent.depth)) {
skip |=
log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(dst_state->image), __LINE__, VALIDATION_ERROR_09c00134, "IMAGE",
+ HandleToUint64(dst_state->image), __LINE__, VALIDATION_ERROR_09c00134, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] dstOffset.z is %d and extent.depth is %d. For 1D and 2D images "
"these must be 0 and 1, respectively. %s",
i, image_copy.dstOffset.z, image_copy.extent.depth, validation_error_map[VALIDATION_ERROR_09c00134]);
if (dst_state->createInfo.imageType == VK_IMAGE_TYPE_3D) {
if ((0 != image_copy.dstSubresource.baseArrayLayer) || (1 != image_copy.dstSubresource.layerCount)) {
skip |= log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(dst_state->image), __LINE__, VALIDATION_ERROR_09c0011a, "IMAGE",
+ HandleToUint64(dst_state->image), __LINE__, VALIDATION_ERROR_09c0011a, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] dstSubresource.baseArrayLayer is %d and dstSubresource.layerCount "
"is %d. For VK_IMAGE_TYPE_3D images these must be 0 and 1, respectively. %s",
i, image_copy.dstSubresource.baseArrayLayer, image_copy.dstSubresource.layerCount,
if ((0 != image_copy.dstSubresource.baseArrayLayer) || (1 != image_copy.dstSubresource.layerCount)) {
skip |=
log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(dst_state->image), __LINE__, VALIDATION_ERROR_09c0011a, "IMAGE",
+ HandleToUint64(dst_state->image), __LINE__, VALIDATION_ERROR_09c0011a, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] dstSubresource.baseArrayLayer is %d and dstSubresource.layerCount "
"is %d. For VK_IMAGE_TYPE_3D images these must be 0 and 1, respectively. %s",
i, image_copy.dstSubresource.baseArrayLayer, image_copy.dstSubresource.layerCount,
} else { // Pre maint 1
if (src_state->createInfo.imageType == VK_IMAGE_TYPE_3D || dst_state->createInfo.imageType == VK_IMAGE_TYPE_3D) {
if ((0 != image_copy.dstSubresource.baseArrayLayer) || (1 != image_copy.dstSubresource.layerCount)) {
- skip |=
- log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(dst_state->image), __LINE__, VALIDATION_ERROR_09c0011a, "IMAGE",
- "vkCmdCopyImage(): pRegion[%d] dstSubresource.baseArrayLayer is %d and "
- "dstSubresource.layerCount is %d. For copies with either source or dest of type "
- "VK_IMAGE_TYPE_3D, these must be 0 and 1, respectively. %s",
- i, image_copy.dstSubresource.baseArrayLayer, image_copy.dstSubresource.layerCount,
- validation_error_map[VALIDATION_ERROR_09c0011a]);
+ skip |= log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
+ HandleToUint64(dst_state->image), __LINE__, VALIDATION_ERROR_09c0011a, "IMAGE",
+ "vkCmdCopyImage(): pRegion[%d] dstSubresource.baseArrayLayer is %d and "
+ "dstSubresource.layerCount is %d. For copies with either source or dest of type "
+ "VK_IMAGE_TYPE_3D, these must be 0 and 1, respectively. %s",
+ i, image_copy.dstSubresource.baseArrayLayer, image_copy.dstSubresource.layerCount,
+ validation_error_map[VALIDATION_ERROR_09c0011a]);
}
}
}
if ((image_copy.dstSubresource.baseArrayLayer >= dst_state->createInfo.arrayLayers) ||
(image_copy.dstSubresource.baseArrayLayer + image_copy.dstSubresource.layerCount > dst_state->createInfo.arrayLayers)) {
skip |= log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(dst_state->image), __LINE__, VALIDATION_ERROR_09c00136, "IMAGE",
+ HandleToUint64(dst_state->image), __LINE__, VALIDATION_ERROR_09c00136, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] dstSubresource.baseArrayLayer (%d) must be less than the dest image's "
"arrayLayers (%d), and the sum of baseArrayLayer and dstSubresource.layerCount (%d) must be less than "
"or equal to the dest image's arrayLayers. %s",
(SafeModulo(image_copy.dstOffset.y, block_size.height) != 0) ||
(SafeModulo(image_copy.dstOffset.z, block_size.depth) != 0)) {
skip |= log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(dst_state->image), __LINE__, VALIDATION_ERROR_09c00144, "IMAGE",
+ HandleToUint64(dst_state->image), __LINE__, VALIDATION_ERROR_09c00144, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] dstOffset (%d, %d) must be multiples of the compressed image's "
"texel width & height (%d, %d). %s.",
i, image_copy.dstOffset.x, image_copy.dstOffset.y, block_size.width, block_size.height,
(adj_extent.width + image_copy.dstOffset.x != mip_extent.width)) {
skip |=
log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(dst_state->image), __LINE__, VALIDATION_ERROR_09c00146, "IMAGE",
+ HandleToUint64(dst_state->image), __LINE__, VALIDATION_ERROR_09c00146, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] extent width (%d) must be a multiple of the compressed texture block "
"width (%d), or when added to dstOffset.x (%d) must equal the image subresource width (%d). %s.",
i, adj_extent.width, block_size.width, image_copy.dstOffset.x, mip_extent.width,
(adj_extent.height + image_copy.dstOffset.y != mip_extent.height)) {
skip |=
log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(dst_state->image), __LINE__, VALIDATION_ERROR_09c00148, "IMAGE",
+ HandleToUint64(dst_state->image), __LINE__, VALIDATION_ERROR_09c00148, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] extent height (%d) must be a multiple of the compressed texture block "
"height (%d), or when added to dstOffset.y (%d) must equal the image subresource height (%d). %s.",
i, adj_extent.height, block_size.height, image_copy.dstOffset.y, mip_extent.height,
if ((SafeModulo(copy_depth, block_size.depth) != 0) && (copy_depth + image_copy.dstOffset.z != mip_extent.depth)) {
skip |=
log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
- reinterpret_cast<const uint64_t &>(dst_state->image), __LINE__, VALIDATION_ERROR_09c0014a, "IMAGE",
+ HandleToUint64(dst_state->image), __LINE__, VALIDATION_ERROR_09c0014a, "IMAGE",
"vkCmdCopyImage(): pRegion[%d] extent width (%d) must be a multiple of the compressed texture block "
"depth (%d), or when added to dstOffset.z (%d) must equal the image subresource depth (%d). %s.",
i, image_copy.extent.depth, block_size.depth, image_copy.dstOffset.z, mip_extent.depth,
ss << "vkCmdCopyImage: number of depth slices in source and destination subresources for pRegions[" << i
<< "] do not match";
skip |= log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
- reinterpret_cast<uint64_t &>(command_buffer), __LINE__, VALIDATION_ERROR_09c00118, "IMAGE",
- "%s. %s", ss.str().c_str(), validation_error_map[VALIDATION_ERROR_09c00118]);
+ HandleToUint64(command_buffer), __LINE__, VALIDATION_ERROR_09c00118, "IMAGE", "%s. %s",
+ ss.str().c_str(), validation_error_map[VALIDATION_ERROR_09c00118]);
}
}
} else {
skip |=
log_msg(report_data, VK_DEBUG_REPORT_PERFORMANCE_WARNING_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(commandBuffer), 0, DRAWSTATE_CLEAR_CMD_BEFORE_DRAW, "DS",
- "vkCmdClearAttachments() issued on command buffer object 0x%p prior to any Draw Cmds."
+ "vkCmdClearAttachments() issued on command buffer object 0x%" PRIx64
+ " prior to any Draw Cmds."
" It is recommended you use RenderPass LOAD_OP_CLEAR on Attachments prior to any Draw.",
- commandBuffer);
+ HandleToUint64(commandBuffer));
}
skip |= outsideRenderPass(device_data, cb_node, "vkCmdClearAttachments()", VALIDATION_ERROR_18600017);
}
if (msgCode == -1) {
// TODO: Fix callers with msgCode == -1 to use correct validation checks.
skip = log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, get_debug_report_enum[obj_type], obj_handle, __LINE__,
- MEMTRACK_INVALID_USAGE_FLAG, "MEM",
- "Invalid usage flag for %s 0x%" PRIxLEAST64
- " used by %s. In this case, %s should have %s set during creation.",
+ MEMTRACK_INVALID_USAGE_FLAG, "MEM", "Invalid usage flag for %s 0x%" PRIx64
+ " used by %s. In this case, %s should have %s set during creation.",
type_str, obj_handle, func_name, type_str, usage_str);
} else {
const char *valid_usage = (msgCode == -1) ? "" : validation_error_map[msgCode];
- skip = log_msg(
- report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, get_debug_report_enum[obj_type], obj_handle, __LINE__, msgCode, "MEM",
- "Invalid usage flag for %s 0x%" PRIxLEAST64 " used by %s. In this case, %s should have %s set during creation. %s",
- type_str, obj_handle, func_name, type_str, usage_str, valid_usage);
+ skip = log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, get_debug_report_enum[obj_type], obj_handle, __LINE__,
+ msgCode, "MEM", "Invalid usage flag for %s 0x%" PRIx64
+ " used by %s. In this case, %s should have %s set during creation. %s",
+ type_str, obj_handle, func_name, type_str, usage_str, valid_usage);
}
}
return skip;
auto buffer_state = GetBufferState(device_data, buffer);
if (!buffer_state) {
skip |= log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_BUFFER_EXT, HandleToUint64(buffer),
- __LINE__, DRAWSTATE_DOUBLE_DESTROY, "DS",
- "Cannot free buffer 0x%" PRIxLEAST64 " that has not been allocated.", HandleToUint64(buffer));
+ __LINE__, DRAWSTATE_DOUBLE_DESTROY, "DS", "Cannot free buffer 0x%" PRIx64 " that has not been allocated.",
+ HandleToUint64(buffer));
} else {
if (buffer_state->in_use.load()) {
skip |= log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_BUFFER_EXT,
HandleToUint64(buffer), __LINE__, VALIDATION_ERROR_23c00734, "DS",
- "Cannot free buffer 0x%" PRIxLEAST64 " that is in use by a command buffer. %s", HandleToUint64(buffer),
+ "Cannot free buffer 0x%" PRIx64 " that is in use by a command buffer. %s", HandleToUint64(buffer),
validation_error_map[VALIDATION_ERROR_23c00734]);
}
}
bool result = false;
if (VK_NULL_HANDLE == mem) {
result = log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT, handle,
- __LINE__, error_code, "MEM", "%s: Vk%s object 0x%" PRIxLEAST64
+ __LINE__, error_code, "MEM", "%s: Vk%s object 0x%" PRIx64
" used with no memory bound. Memory should be bound by calling "
"vkBind%sMemory(). %s",
api_name, type_name, handle, type_name, validation_error_map[error_code]);
} else if (MEMORY_UNBOUND == mem) {
result = log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT, handle,
- __LINE__, error_code, "MEM", "%s: Vk%s object 0x%" PRIxLEAST64
+ __LINE__, error_code, "MEM", "%s: Vk%s object 0x%" PRIx64
" used with no memory bound and previously bound memory was freed. "
"Memory must not be freed prior to this operation. %s",
api_name, type_name, handle, validation_error_map[error_code]);
}
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DEVICE_MEMORY_EXT,
HandleToUint64(mem), __LINE__, error_code, "MEM",
- "In %s, attempting to bind memory (0x%" PRIxLEAST64 ") to object (0x%" PRIxLEAST64
+ "In %s, attempting to bind memory (0x%" PRIx64 ") to object (0x%" PRIx64
") which was created with sparse memory flags (VK_%s_CREATE_SPARSE_*_BIT). %s",
apiName, HandleToUint64(mem), handle, handle_type, validation_error_map[error_code]);
}
}
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DEVICE_MEMORY_EXT,
HandleToUint64(mem), __LINE__, error_code, "MEM",
- "In %s, attempting to bind memory (0x%" PRIxLEAST64 ") to object (0x%" PRIxLEAST64
- ") which has already been bound to mem object 0x%" PRIxLEAST64 ". %s",
+ "In %s, attempting to bind memory (0x%" PRIx64 ") to object (0x%" PRIx64
+ ") which has already been bound to mem object 0x%" PRIx64 ". %s",
apiName, HandleToUint64(mem), handle, HandleToUint64(prev_binding->mem),
validation_error_map[error_code]);
} else if (mem_binding->binding.mem == MEMORY_UNBOUND) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DEVICE_MEMORY_EXT,
HandleToUint64(mem), __LINE__, MEMTRACK_REBIND_OBJECT, "MEM",
- "In %s, attempting to bind memory (0x%" PRIxLEAST64 ") to object (0x%" PRIxLEAST64
+ "In %s, attempting to bind memory (0x%" PRIx64 ") to object (0x%" PRIx64
") which was previous bound to memory that has since been freed. Memory bindings are immutable in "
"Vulkan so this attempt to bind to new memory is not allowed.",
apiName, HandleToUint64(mem), handle);
if (!(pNode->status & status_mask)) {
char const *const message = validation_error_map[msg_code];
return log_msg(dev_data->report_data, msg_flags, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
- HandleToUint64(pNode->commandBuffer), __LINE__, msg_code, "DS", "command buffer object 0x%p: %s. %s.",
- pNode->commandBuffer, fail_msg, message);
+ HandleToUint64(pNode->commandBuffer), __LINE__, msg_code, "DS",
+ "command buffer object 0x%" PRIx64 ": %s. %s.", HandleToUint64(pNode->commandBuffer), fail_msg, message);
}
return false;
}
skip |=
log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(pCB->commandBuffer), __LINE__, DRAWSTATE_VTX_INDEX_OUT_OF_BOUNDS, "DS",
- "The Pipeline State Object (0x%" PRIxLEAST64
+ "The Pipeline State Object (0x%" PRIx64
") expects that this Command Buffer's vertex binding Index %u "
"should be set via vkCmdBindVertexBuffers. This is because VkVertexInputBindingDescription struct "
"at index " PRINTF_SIZE_T_SPECIFIER " of pVertexBindingDescriptions has a binding value of %u.",
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_PERFORMANCE_WARNING_BIT_EXT,
VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, HandleToUint64(pCB->commandBuffer), __LINE__,
DRAWSTATE_VTX_INDEX_OUT_OF_BOUNDS, "DS",
- "Vertex buffers are bound to command buffer (0x%p"
- ") but no vertex buffers are attached to this Pipeline State Object (0x%" PRIxLEAST64 ").",
- pCB->commandBuffer, HandleToUint64(state.pipeline_state->pipeline));
+ "Vertex buffers are bound to command buffer (0x%" PRIx64
+ ") but no vertex buffers are attached to this Pipeline State Object (0x%" PRIx64 ").",
+ HandleToUint64(pCB->commandBuffer), HandleToUint64(state.pipeline_state->pipeline));
}
}
// If Viewport or scissors are dynamic, verify that dynamic count matches PSO count.
((subpass_num_samples & static_cast<unsigned>(pso_num_samples)) != subpass_num_samples)) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_PIPELINE_EXT,
HandleToUint64(pPipeline->pipeline), __LINE__, DRAWSTATE_NUM_SAMPLES_MISMATCH, "DS",
- "Num samples mismatch! At draw-time in Pipeline (0x%" PRIxLEAST64
- ") with %u samples while current RenderPass (0x%" PRIxLEAST64 ") w/ %u samples!",
+ "Num samples mismatch! At draw-time in Pipeline (0x%" PRIx64
+ ") with %u samples while current RenderPass (0x%" PRIx64 ") w/ %u samples!",
HandleToUint64(pPipeline->pipeline), pso_num_samples,
HandleToUint64(pCB->activeRenderPass->renderPass), subpass_num_samples);
}
} else {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_PIPELINE_EXT,
HandleToUint64(pPipeline->pipeline), __LINE__, DRAWSTATE_NUM_SAMPLES_MISMATCH, "DS",
- "No active render pass found at draw-time in Pipeline (0x%" PRIxLEAST64 ")!",
+ "No active render pass found at draw-time in Pipeline (0x%" PRIx64 ")!",
HandleToUint64(pPipeline->pipeline));
}
}
uint32_t setIndex = set_binding_pair.first;
// If valid set is not bound throw an error
if ((state.boundDescriptorSets.size() <= setIndex) || (!state.boundDescriptorSets[setIndex])) {
- result |=
- log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
- HandleToUint64(cb_node->commandBuffer), __LINE__, DRAWSTATE_DESCRIPTOR_SET_NOT_BOUND, "DS",
- "VkPipeline 0x%" PRIxLEAST64 " uses set #%u but that set is not bound.",
- HandleToUint64(pPipe->pipeline), setIndex);
+ result |= log_msg(
+ dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
+ HandleToUint64(cb_node->commandBuffer), __LINE__, DRAWSTATE_DESCRIPTOR_SET_NOT_BOUND, "DS",
+ "VkPipeline 0x%" PRIx64 " uses set #%u but that set is not bound.", HandleToUint64(pPipe->pipeline), setIndex);
} else if (!verify_set_layout_compatibility(state.boundDescriptorSets[setIndex], &pipeline_layout, setIndex,
errorString)) {
// Set is bound but not compatible w/ overlapping pipeline_layout from PSO
result |=
log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DESCRIPTOR_SET_EXT,
HandleToUint64(setHandle), __LINE__, DRAWSTATE_PIPELINE_LAYOUTS_INCOMPATIBLE, "DS",
- "VkDescriptorSet (0x%" PRIxLEAST64
- ") bound as set #%u is not compatible with overlapping VkPipelineLayout 0x%" PRIxLEAST64 " due to: %s",
+ "VkDescriptorSet (0x%" PRIx64
+ ") bound as set #%u is not compatible with overlapping VkPipelineLayout 0x%" PRIx64 " due to: %s",
HandleToUint64(setHandle), setIndex, HandleToUint64(pipeline_layout.layout), errorString.c_str());
} else { // Valid set is bound and layout compatible, validate that it's updated
// Pull the set node
result |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT,
VK_DEBUG_REPORT_OBJECT_TYPE_DESCRIPTOR_SET_EXT, HandleToUint64(set), __LINE__,
DRAWSTATE_DESCRIPTOR_SET_NOT_UPDATED, "DS",
- "Descriptor set 0x%" PRIxLEAST64 " encountered the following validation error at %s time: %s",
+ "Descriptor set 0x%" PRIx64 " encountered the following validation error at %s time: %s",
HandleToUint64(set), function, err_str.c_str());
}
}
skip |= log_msg(
dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_PIPELINE_EXT,
HandleToUint64(pPipeline->pipeline), __LINE__, VALIDATION_ERROR_096005d4, "DS",
- "vkCreateGraphicsPipelines(): Render pass (0x%" PRIxLEAST64
+ "vkCreateGraphicsPipelines(): Render pass (0x%" PRIx64
") subpass %u has colorAttachmentCount of %u which doesn't match the pColorBlendState->attachmentCount of %u. %s",
HandleToUint64(pPipeline->rp_state->renderPass), pPipeline->graphicsPipelineCI.subpass,
subpass_desc->colorAttachmentCount, color_blend_state->attachmentCount,
if (set_node == dev_data->setMap.end()) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DESCRIPTOR_SET_EXT,
HandleToUint64(set), __LINE__, DRAWSTATE_DOUBLE_DESTROY, "DS",
- "Cannot call %s() on descriptor set 0x%" PRIxLEAST64 " that has not been allocated.", func_str.c_str(),
+ "Cannot call %s() on descriptor set 0x%" PRIx64 " that has not been allocated.", func_str.c_str(),
HandleToUint64(set));
} else {
// TODO : This covers various error cases so should pass error enum into this function and use passed in enum here
if (set_node->second->in_use.load()) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DESCRIPTOR_SET_EXT,
HandleToUint64(set), __LINE__, VALIDATION_ERROR_2860026a, "DS",
- "Cannot call %s() on descriptor set 0x%" PRIxLEAST64 " that is in use by a command buffer. %s",
+ "Cannot call %s() on descriptor set 0x%" PRIx64 " that is in use by a command buffer. %s",
func_str.c_str(), HandleToUint64(set), validation_error_map[VALIDATION_ERROR_2860026a]);
}
}
const char *cause_str = GetCauseStr(obj);
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(cb_state->commandBuffer), __LINE__, DRAWSTATE_INVALID_COMMAND_BUFFER, "DS",
- "You are adding %s to command buffer 0x%p that is invalid because bound %s 0x%" PRIxLEAST64 " was %s.",
- call_source, cb_state->commandBuffer, type_str, obj.handle, cause_str);
+ "You are adding %s to command buffer 0x%" PRIx64 " that is invalid because bound %s 0x%" PRIx64 " was %s.",
+ call_source, HandleToUint64(cb_state->commandBuffer), type_str, obj.handle, cause_str);
}
return skip;
}
if (pCB->activeRenderPass) {
inside = log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(pCB->commandBuffer), __LINE__, msgCode, "DS",
- "%s: It is invalid to issue this call inside an active render pass (0x%" PRIxLEAST64 "). %s", apiName,
+ "%s: It is invalid to issue this call inside an active render pass (0x%" PRIx64 "). %s", apiName,
HandleToUint64(pCB->activeRenderPass->renderPass), validation_error_map[msgCode]);
}
return inside;
!(pCB->beginInfo.flags & VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT)) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, 0,
__LINE__, VALIDATION_ERROR_31a0008e, "DS",
- "Command Buffer 0x%p is already in use and is not marked for simultaneous use. %s", pCB->commandBuffer,
- validation_error_map[VALIDATION_ERROR_31a0008e]);
+ "Command Buffer 0x%" PRIx64 " is already in use and is not marked for simultaneous use. %s",
+ HandleToUint64(pCB->commandBuffer), validation_error_map[VALIDATION_ERROR_31a0008e]);
}
return skip;
}
(cb_state->submitCount + current_submit_count > 1)) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, 0,
__LINE__, DRAWSTATE_COMMAND_BUFFER_SINGLE_SUBMIT_VIOLATION, "DS",
- "Commandbuffer 0x%p was begun w/ VK_COMMAND_BUFFER_USAGE_ONE_TIME_SUBMIT_BIT "
+ "Commandbuffer 0x%" PRIx64
+ " was begun w/ VK_COMMAND_BUFFER_USAGE_ONE_TIME_SUBMIT_BIT "
"set, but has been submitted 0x%" PRIxLEAST64 " times.",
- cb_state->commandBuffer, cb_state->submitCount + current_submit_count);
+ HandleToUint64(cb_state->commandBuffer), cb_state->submitCount + current_submit_count);
}
// Validate that cmd buffers have been updated
case CB_NEW:
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
(uint64_t)(cb_state->commandBuffer), __LINE__, vu_id, "DS",
- "Command buffer 0x%p used in the call to %s is unrecorded and contains no commands. %s",
- cb_state->commandBuffer, call_source, validation_error_map[vu_id]);
+ "Command buffer 0x%" PRIx64 " used in the call to %s is unrecorded and contains no commands. %s",
+ HandleToUint64(cb_state->commandBuffer), call_source, validation_error_map[vu_id]);
break;
case CB_RECORDING:
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(cb_state->commandBuffer), __LINE__, DRAWSTATE_NO_END_COMMAND_BUFFER, "DS",
- "You must call vkEndCommandBuffer() on command buffer 0x%p before this call to %s!",
- cb_state->commandBuffer, call_source);
+ "You must call vkEndCommandBuffer() on command buffer 0x%" PRIx64 " before this call to %s!",
+ HandleToUint64(cb_state->commandBuffer), call_source);
break;
default: /* recorded */
if (!found) {
skip = log_msg(
dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, get_debug_report_enum[object->type], object->handle, __LINE__,
- DRAWSTATE_INVALID_QUEUE_FAMILY, "DS", "vkQueueSubmit: Command buffer 0x%" PRIxLEAST64 " contains %s 0x%" PRIxLEAST64
+ DRAWSTATE_INVALID_QUEUE_FAMILY, "DS", "vkQueueSubmit: Command buffer 0x%" PRIx64 " contains %s 0x%" PRIx64
" which was not created allowing concurrent access to this queue family %d.",
HandleToUint64(cb_node->commandBuffer), object_string[object->type], object->handle, queue_state->queueFamilyIndex);
}
if (pPool->queueFamilyIndex != queue_state->queueFamilyIndex) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(pCB->commandBuffer), __LINE__, VALIDATION_ERROR_31a00094, "DS",
- "vkQueueSubmit: Primary command buffer 0x%p created in queue family %d is being submitted on queue "
- "0x%p from queue family %d. %s",
- pCB->commandBuffer, pPool->queueFamilyIndex, queue, queue_state->queueFamilyIndex,
- validation_error_map[VALIDATION_ERROR_31a00094]);
+ "vkQueueSubmit: Primary command buffer 0x%" PRIx64
+ " created in queue family %d is being submitted on queue "
+ "0x%" PRIx64 " from queue family %d. %s",
+ HandleToUint64(pCB->commandBuffer), pPool->queueFamilyIndex, HandleToUint64(queue),
+ queue_state->queueFamilyIndex, validation_error_map[VALIDATION_ERROR_31a00094]);
}
// Ensure that any bound images or buffers created with SHARING_MODE_CONCURRENT have access to the current queue family
!(pSubCB->beginInfo.flags & VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT)) {
log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, 0,
__LINE__, VALIDATION_ERROR_31a00092, "DS",
- "Commandbuffer 0x%p was submitted with secondary buffer 0x%p but that buffer has subsequently been bound to "
- "primary cmd buffer 0x%p and it does not have VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT set. %s",
- pCB->commandBuffer, pSubCB->commandBuffer, pSubCB->primaryCommandBuffer,
- validation_error_map[VALIDATION_ERROR_31a00092]);
+ "Commandbuffer 0x%" PRIx64 " was submitted with secondary buffer 0x%" PRIx64
+ " but that buffer has subsequently been bound to "
+ "primary cmd buffer 0x%" PRIx64 " and it does not have VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT set. %s",
+ HandleToUint64(pCB->commandBuffer), HandleToUint64(pSubCB->commandBuffer),
+ HandleToUint64(pSubCB->primaryCommandBuffer), validation_error_map[VALIDATION_ERROR_31a00092]);
}
}
// TODO: opportunities for VALIDATION_ERROR_31a0007e, VALIDATION_ERROR_316008b2, VALIDATION_ERROR_16400a0e
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_FENCE_EXT,
HandleToUint64(pFence->fence), __LINE__, MEMTRACK_INVALID_FENCE_STATE, "MEM",
- "Fence 0x%" PRIxLEAST64 " submitted in SIGNALED state. Fences must be reset before being submitted",
+ "Fence 0x%" PRIx64 " submitted in SIGNALED state. Fences must be reset before being submitted",
HandleToUint64(pFence->fence));
}
}
(!(signaled_semaphores.count(semaphore)) && !(pSemaphore->signaled))) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_SEMAPHORE_EXT,
HandleToUint64(semaphore), __LINE__, DRAWSTATE_QUEUE_FORWARD_PROGRESS, "DS",
- "Queue 0x%p is waiting on semaphore 0x%" PRIx64 " that has no way to be signaled.", queue,
- HandleToUint64(semaphore));
+ "Queue 0x%" PRIx64 " is waiting on semaphore 0x%" PRIx64 " that has no way to be signaled.",
+ HandleToUint64(queue), HandleToUint64(semaphore));
} else {
signaled_semaphores.erase(semaphore);
unsignaled_semaphores.insert(semaphore);
if (signaled_semaphores.count(semaphore) || (!(unsignaled_semaphores.count(semaphore)) && pSemaphore->signaled)) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_SEMAPHORE_EXT,
HandleToUint64(semaphore), __LINE__, DRAWSTATE_QUEUE_FORWARD_PROGRESS, "DS",
- "Queue 0x%p is signaling semaphore 0x%" PRIx64
+ "Queue 0x%" PRIx64 " is signaling semaphore 0x%" PRIx64
" that has already been signaled but not waited on by queue 0x%" PRIx64 ".",
- queue, HandleToUint64(semaphore), HandleToUint64(pSemaphore->signaler.first));
+ HandleToUint64(queue), HandleToUint64(semaphore), HandleToUint64(pSemaphore->signaler.first));
} else {
unsignaled_semaphores.erase(semaphore);
signaled_semaphores.insert(semaphore);
// Clear mem binding for any bound objects
for (auto obj : mem_info->obj_bindings) {
log_msg(dev_data->report_data, VK_DEBUG_REPORT_INFORMATION_BIT_EXT, get_debug_report_enum[obj.type], obj.handle, __LINE__,
- MEMTRACK_FREED_MEM_REF, "MEM", "VK Object 0x%" PRIxLEAST64 " still has a reference to mem obj 0x%" PRIxLEAST64,
- obj.handle, HandleToUint64(mem_info->mem));
+ MEMTRACK_FREED_MEM_REF, "MEM", "VK Object 0x%" PRIx64 " still has a reference to mem obj 0x%" PRIx64,
+ HandleToUint64(obj.handle), HandleToUint64(mem_info->mem));
switch (obj.type) {
case kVulkanObjectTypeImage: {
auto image_state = GetImageState(dev_data, reinterpret_cast<VkImage &>(obj.handle));
auto mem_info = mem_element->second.get();
// It is an application error to call VkMapMemory on an object that is already mapped
if (mem_info->mem_range.size != 0) {
- skip =
- log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DEVICE_MEMORY_EXT,
- HandleToUint64(mem), __LINE__, MEMTRACK_INVALID_MAP, "MEM",
- "VkMapMemory: Attempting to map memory on an already-mapped object 0x%" PRIxLEAST64, HandleToUint64(mem));
+ skip = log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DEVICE_MEMORY_EXT,
+ HandleToUint64(mem), __LINE__, MEMTRACK_INVALID_MAP, "MEM",
+ "VkMapMemory: Attempting to map memory on an already-mapped object 0x%" PRIx64, HandleToUint64(mem));
}
// Validate that offset + size is within object's allocationSize
// Valid Usage: memory must currently be mapped
skip = log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DEVICE_MEMORY_EXT,
HandleToUint64(mem), __LINE__, VALIDATION_ERROR_33600562, "MEM",
- "Unmapping Memory without memory being mapped: mem obj 0x%" PRIxLEAST64 ". %s", HandleToUint64(mem),
+ "Unmapping Memory without memory being mapped: mem obj 0x%" PRIx64 ". %s", HandleToUint64(mem),
validation_error_map[VALIDATION_ERROR_33600562]);
}
mem_info->mem_range.size = 0;
if (pFence->state == FENCE_UNSIGNALED) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_WARNING_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_FENCE_EXT,
HandleToUint64(fence), __LINE__, MEMTRACK_INVALID_FENCE_STATE, "MEM",
- "%s called for fence 0x%" PRIxLEAST64
+ "%s called for fence 0x%" PRIx64
" which has not been submitted on a Queue or during "
"acquire next image.",
apiCall, HandleToUint64(fence));
UNIQUE_VALIDATION_ERROR_CODE error_code = is_image ? VALIDATION_ERROR_1740082c : VALIDATION_ERROR_1700080e;
skip = log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DEVICE_MEMORY_EXT,
HandleToUint64(mem_info->mem), __LINE__, error_code, "MEM",
- "In %s, attempting to bind memory (0x%" PRIxLEAST64 ") to object (0x%" PRIxLEAST64
- "), memoryOffset=0x%" PRIxLEAST64 " must be less than the memory allocation size 0x%" PRIxLEAST64 ". %s",
- api_name, HandleToUint64(mem_info->mem), handle, memoryOffset, mem_info->alloc_info.allocationSize,
- validation_error_map[error_code]);
+ "In %s, attempting to bind memory (0x%" PRIx64 ") to object (0x%" PRIx64 "), memoryOffset=0x%" PRIxLEAST64
+ " must be less than the memory allocation size 0x%" PRIxLEAST64 ". %s",
+ api_name, HandleToUint64(mem_info->mem), HandleToUint64(handle), memoryOffset,
+ mem_info->alloc_info.allocationSize, validation_error_map[error_code]);
}
return skip;
// vkGetBufferMemoryRequirements()
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_WARNING_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_BUFFER_EXT,
buffer_handle, __LINE__, DRAWSTATE_INVALID_BUFFER, "DS",
- "vkBindBufferMemory(): Binding memory to buffer 0x%" PRIxLEAST64
+ "vkBindBufferMemory(): Binding memory to buffer 0x%" PRIx64
" but vkGetBufferMemoryRequirements() has not been called on that buffer.",
- buffer_handle);
+ HandleToUint64(buffer_handle));
// Make the call for them so we can verify the state
lock.unlock();
dev_data->dispatch_table.GetBufferMemoryRequirements(dev_data->device, buffer, &buffer_state->requirements);
if (cb_node->in_use.load()) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(cb_node->commandBuffer), __LINE__, error_code, "DS",
- "Attempt to %s command buffer (0x%p) which is in use. %s", action, cb_node->commandBuffer,
- validation_error_map[error_code]);
+ "Attempt to %s command buffer (0x%" PRIx64 ") which is in use. %s", action,
+ HandleToUint64(cb_node->commandBuffer), validation_error_map[error_code]);
}
return skip;
}
if (cb_node->state == CB_RECORDING) {
log_msg(dev_data->report_data, VK_DEBUG_REPORT_WARNING_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(cb_node->commandBuffer), __LINE__, DRAWSTATE_INVALID_COMMAND_BUFFER, "DS",
- "Invalidating a command buffer that's currently being recorded: 0x%p.", cb_node->commandBuffer);
+ "Invalidating a command buffer that's currently being recorded: 0x%" PRIx64 ".",
+ HandleToUint64(cb_node->commandBuffer));
cb_node->state = CB_INVALID_INCOMPLETE;
}
else if (cb_node->state == CB_RECORDED) {
if (src[i] == dst) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_VALIDATION_CACHE_EXT,
0, __LINE__, VALIDATION_ERROR_3e600c00, "DS",
- "vkMergeValidationCachesEXT: dstCache (0x%" PRIxLEAST64 ") must not appear in pSrcCaches array. %s",
+ "vkMergeValidationCachesEXT: dstCache (0x%" PRIx64 ") must not appear in pSrcCaches array. %s",
HandleToUint64(dstCache), validation_error_map[VALIDATION_ERROR_3e600c00]);
result = VK_ERROR_VALIDATION_FAILED_EXT;
}
skip |=
log_msg(device_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_PIPELINE_EXT,
HandleToUint64(pipe_state->pipeline), __LINE__, DRAWSTATE_INVALID_FEATURE, "DS",
- "CmdBindPipeline: vkPipeline (0x%" PRIxLEAST64 ") attachment[" PRINTF_SIZE_T_SPECIFIER
+ "CmdBindPipeline: vkPipeline (0x%" PRIx64 ") attachment[" PRINTF_SIZE_T_SPECIFIER
"] has a dual-source blend factor but this device feature is not enabled.",
HandleToUint64(pipe_state->pipeline), i);
}
if (cb_node->in_use.load()) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(commandBuffer), __LINE__, VALIDATION_ERROR_16e00062, "MEM",
- "Calling vkBeginCommandBuffer() on active command buffer %p before it has completed. "
+ "Calling vkBeginCommandBuffer() on active command buffer %" PRIx64
+ " before it has completed. "
"You must check command buffer fence before this call. %s",
- commandBuffer, validation_error_map[VALIDATION_ERROR_16e00062]);
+ HandleToUint64(commandBuffer), validation_error_map[VALIDATION_ERROR_16e00062]);
}
clear_cmd_buf_and_mem_references(dev_data, cb_node);
if (cb_node->createInfo.level != VK_COMMAND_BUFFER_LEVEL_PRIMARY) {
skip |=
log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(commandBuffer), __LINE__, VALIDATION_ERROR_16e00066, "DS",
- "vkBeginCommandBuffer(): Secondary Command Buffer (0x%p) must have inheritance info. %s", commandBuffer,
- validation_error_map[VALIDATION_ERROR_16e00066]);
+ "vkBeginCommandBuffer(): Secondary Command Buffer (0x%" PRIx64 ") must have inheritance info. %s",
+ HandleToUint64(commandBuffer), validation_error_map[VALIDATION_ERROR_16e00066]);
} else {
if (pBeginInfo->flags & VK_COMMAND_BUFFER_USAGE_RENDER_PASS_CONTINUE_BIT) {
assert(pInfo->renderPass);
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT,
VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, HandleToUint64(commandBuffer), __LINE__,
VALIDATION_ERROR_16e00068, "DS",
- "vkBeginCommandBuffer(): Secondary Command Buffer (0x%p) must not have "
+ "vkBeginCommandBuffer(): Secondary Command Buffer (0x%" PRIx64
+ ") must not have "
"VK_QUERY_CONTROL_PRECISE_BIT if occulusionQuery is disabled or the device does not "
"support precise occlusion queries. %s",
- commandBuffer, validation_error_map[VALIDATION_ERROR_16e00068]);
+ HandleToUint64(commandBuffer), validation_error_map[VALIDATION_ERROR_16e00068]);
}
}
if (pInfo && pInfo->renderPass != VK_NULL_HANDLE) {
auto renderPass = GetRenderPassState(dev_data, pInfo->renderPass);
if (renderPass) {
if (pInfo->subpass >= renderPass->createInfo.subpassCount) {
- skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT,
- VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, HandleToUint64(commandBuffer), __LINE__,
- VALIDATION_ERROR_0280006c, "DS",
- "vkBeginCommandBuffer(): Secondary Command Buffers (0x%p) must have a subpass index (%d) "
- "that is less than the number of subpasses (%d). %s",
- commandBuffer, pInfo->subpass, renderPass->createInfo.subpassCount,
- validation_error_map[VALIDATION_ERROR_0280006c]);
+ skip |=
+ log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT,
+ VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, HandleToUint64(commandBuffer), __LINE__,
+ VALIDATION_ERROR_0280006c, "DS", "vkBeginCommandBuffer(): Secondary Command Buffers (0x%" PRIx64
+ ") must have a subpass index (%d) "
+ "that is less than the number of subpasses (%d). %s",
+ HandleToUint64(commandBuffer), pInfo->subpass, renderPass->createInfo.subpassCount,
+ validation_error_map[VALIDATION_ERROR_0280006c]);
}
}
}
if (CB_RECORDING == cb_node->state) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(commandBuffer), __LINE__, VALIDATION_ERROR_16e00062, "DS",
- "vkBeginCommandBuffer(): Cannot call Begin on command buffer (0x%p"
+ "vkBeginCommandBuffer(): Cannot call Begin on command buffer (0x%" PRIx64
") in the RECORDING state. Must first call vkEndCommandBuffer(). %s",
- commandBuffer, validation_error_map[VALIDATION_ERROR_16e00062]);
+ HandleToUint64(commandBuffer), validation_error_map[VALIDATION_ERROR_16e00062]);
} else if (CB_RECORDED == cb_node->state || CB_INVALID_COMPLETE == cb_node->state) {
VkCommandPool cmdPool = cb_node->createInfo.commandPool;
auto pPool = GetCommandPoolNode(dev_data, cmdPool);
if (!(VK_COMMAND_POOL_CREATE_RESET_COMMAND_BUFFER_BIT & pPool->createFlags)) {
- skip |=
- log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
- HandleToUint64(commandBuffer), __LINE__, VALIDATION_ERROR_16e00064, "DS",
- "Call to vkBeginCommandBuffer() on command buffer (0x%p"
- ") attempts to implicitly reset cmdBuffer created from command pool (0x%" PRIxLEAST64
- ") that does NOT have the VK_COMMAND_POOL_CREATE_RESET_COMMAND_BUFFER_BIT bit set. %s",
- commandBuffer, HandleToUint64(cmdPool), validation_error_map[VALIDATION_ERROR_16e00064]);
+ skip |= log_msg(
+ dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
+ HandleToUint64(commandBuffer), __LINE__, VALIDATION_ERROR_16e00064, "DS",
+ "Call to vkBeginCommandBuffer() on command buffer (0x%" PRIx64
+ ") attempts to implicitly reset cmdBuffer created from command pool (0x%" PRIx64
+ ") that does NOT have the VK_COMMAND_POOL_CREATE_RESET_COMMAND_BUFFER_BIT bit set. %s",
+ HandleToUint64(commandBuffer), HandleToUint64(cmdPool), validation_error_map[VALIDATION_ERROR_16e00064]);
}
ResetCommandBufferState(dev_data, commandBuffer);
}
if (!(VK_COMMAND_POOL_CREATE_RESET_COMMAND_BUFFER_BIT & pPool->createFlags)) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(commandBuffer), __LINE__, VALIDATION_ERROR_3260005c, "DS",
- "Attempt to reset command buffer (0x%p) created from command pool (0x%" PRIxLEAST64
+ "Attempt to reset command buffer (0x%" PRIx64 ") created from command pool (0x%" PRIx64
") that does NOT have the VK_COMMAND_POOL_CREATE_RESET_COMMAND_BUFFER_BIT bit set. %s",
- commandBuffer, HandleToUint64(cmdPool), validation_error_map[VALIDATION_ERROR_3260005c]);
+ HandleToUint64(commandBuffer), HandleToUint64(cmdPool), validation_error_map[VALIDATION_ERROR_3260005c]);
}
skip |= checkCommandBufferInFlight(dev_data, pCB, "reset", VALIDATION_ERROR_3260005a);
lock.unlock();
cvdescriptorset::DescriptorSet *descriptor_set = GetSetNode(device_data, pDescriptorSets[set_idx]);
if (descriptor_set) {
if (!descriptor_set->IsUpdated() && (descriptor_set->GetTotalDescriptorCount() != 0)) {
- skip |= log_msg(device_data->report_data, VK_DEBUG_REPORT_WARNING_BIT_EXT,
- VK_DEBUG_REPORT_OBJECT_TYPE_DESCRIPTOR_SET_EXT, HandleToUint64(pDescriptorSets[set_idx]), __LINE__,
- DRAWSTATE_DESCRIPTOR_SET_NOT_UPDATED, "DS",
- "Descriptor Set 0x%" PRIxLEAST64
- " bound but it was never updated. You may want to either update it or not bind it.",
- HandleToUint64(pDescriptorSets[set_idx]));
+ skip |= log_msg(
+ device_data->report_data, VK_DEBUG_REPORT_WARNING_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DESCRIPTOR_SET_EXT,
+ HandleToUint64(pDescriptorSets[set_idx]), __LINE__, DRAWSTATE_DESCRIPTOR_SET_NOT_UPDATED, "DS",
+ "Descriptor Set 0x%" PRIx64 " bound but it was never updated. You may want to either update it or not bind it.",
+ HandleToUint64(pDescriptorSets[set_idx]));
}
// Verify that set being bound is compatible with overlapping setLayout of pipelineLayout
if (!verify_set_layout_compatibility(descriptor_set, pipeline_layout, set_idx + firstSet, error_string)) {
log_msg(device_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DESCRIPTOR_SET_EXT,
HandleToUint64(pDescriptorSets[set_idx]), __LINE__, VALIDATION_ERROR_17c002cc, "DS",
"descriptorSet #%u being bound is not compatible with overlapping descriptorSetLayout "
- "at index %u of pipelineLayout 0x%" PRIxLEAST64 " due to: %s. %s",
+ "at index %u of pipelineLayout 0x%" PRIx64 " due to: %s. %s",
set_idx, set_idx + firstSet, HandleToUint64(layout), error_string.c_str(),
validation_error_map[VALIDATION_ERROR_17c002cc]);
}
skip |= log_msg(device_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT,
VK_DEBUG_REPORT_OBJECT_TYPE_DESCRIPTOR_SET_EXT, HandleToUint64(pDescriptorSets[set_idx]),
__LINE__, DRAWSTATE_INVALID_DYNAMIC_OFFSET_COUNT, "DS",
- "descriptorSet #%u (0x%" PRIxLEAST64
+ "descriptorSet #%u (0x%" PRIx64
") requires %u dynamicOffsets, but only %u dynamicOffsets are left in pDynamicOffsets "
"array. There must be one dynamic offset for each dynamic descriptor being bound.",
set_idx, HandleToUint64(pDescriptorSets[set_idx]), descriptor_set->GetDynamicDescriptorCount(),
} else {
skip |= log_msg(device_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DESCRIPTOR_SET_EXT,
HandleToUint64(pDescriptorSets[set_idx]), __LINE__, DRAWSTATE_INVALID_SET, "DS",
- "Attempt to bind descriptor set 0x%" PRIxLEAST64 " that doesn't exist!",
+ "Attempt to bind descriptor set 0x%" PRIx64 " that doesn't exist!",
HandleToUint64(pDescriptorSets[set_idx]));
}
}
if (image_state->createInfo.samples != sample_count) {
skip = log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
HandleToUint64(image_state->image), 0, msgCode, "DS",
- "%s for image 0x%" PRIxLEAST64 " was created with a sample count of %s but must be %s. %s", location,
+ "%s for image 0x%" PRIx64 " was created with a sample count of %s but must be %s. %s", location,
HandleToUint64(image_state->image), string_VkSampleCountFlagBits(image_state->createInfo.samples),
string_VkSampleCountFlagBits(sample_count), validation_error_map[msgCode]);
}
dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_RENDER_PASS_EXT,
HandleToUint64(pCreateInfo->renderPass), __LINE__, VALIDATION_ERROR_094006d8, "DS",
"vkCreateFramebuffer(): VkFramebufferCreateInfo attachmentCount of %u does not match attachmentCount of %u of "
- "renderPass (0x%" PRIxLEAST64 ") being used to create Framebuffer. %s",
+ "renderPass (0x%" PRIx64 ") being used to create Framebuffer. %s",
pCreateInfo->attachmentCount, rpci->attachmentCount, HandleToUint64(pCreateInfo->renderPass),
validation_error_map[VALIDATION_ERROR_094006d8]);
} else {
HandleToUint64(pCreateInfo->renderPass), __LINE__, VALIDATION_ERROR_094006e0, "DS",
"vkCreateFramebuffer(): VkFramebufferCreateInfo attachment #%u has format of %s that does not match "
"the format of "
- "%s used by the corresponding attachment for renderPass (0x%" PRIxLEAST64 "). %s",
+ "%s used by the corresponding attachment for renderPass (0x%" PRIx64 "). %s",
i, string_VkFormat(ivci.format), string_VkFormat(rpci->pAttachments[i].format),
HandleToUint64(pCreateInfo->renderPass), validation_error_map[VALIDATION_ERROR_094006e0]);
}
dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_RENDER_PASS_EXT,
HandleToUint64(pCreateInfo->renderPass), __LINE__, VALIDATION_ERROR_094006e2, "DS",
"vkCreateFramebuffer(): VkFramebufferCreateInfo attachment #%u has %s samples that do not match "
- "the %s samples used by the corresponding attachment for renderPass (0x%" PRIxLEAST64 "). %s",
+ "the %s samples used by the corresponding attachment for renderPass (0x%" PRIx64 "). %s",
i, string_VkSampleCountFlagBits(ici->samples), string_VkSampleCountFlagBits(rpci->pAttachments[i].samples),
HandleToUint64(pCreateInfo->renderPass), validation_error_map[VALIDATION_ERROR_094006e2]);
}
if (!fb) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(primaryBuffer), __LINE__, DRAWSTATE_INVALID_SECONDARY_COMMAND_BUFFER, "DS",
- "vkCmdExecuteCommands() called w/ invalid Cmd Buffer 0x%p "
- "which has invalid framebuffer 0x%" PRIx64 ".",
- (void *)secondaryBuffer, HandleToUint64(secondary_fb));
+ "vkCmdExecuteCommands() called w/ invalid Cmd Buffer 0x%" PRIx64
+ " which has invalid framebuffer 0x%" PRIx64 ".",
+ HandleToUint64(secondaryBuffer), HandleToUint64(secondary_fb));
return skip;
}
}
pSubCB->beginInfo.pInheritanceInfo) {
VkQueryPipelineStatisticFlags cmdBufStatistics = pSubCB->beginInfo.pInheritanceInfo->pipelineStatistics;
if ((cmdBufStatistics & queryPoolData->second.createInfo.pipelineStatistics) != cmdBufStatistics) {
- skip |= log_msg(
- dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
- HandleToUint64(pCB->commandBuffer), __LINE__, VALIDATION_ERROR_1b2000d0, "DS",
- "vkCmdExecuteCommands() called w/ invalid Cmd Buffer 0x%p "
- "which has invalid active query pool 0x%" PRIx64
- ". Pipeline statistics is being queried so the command "
- "buffer must have all bits set on the queryPool. %s",
- pCB->commandBuffer, HandleToUint64(queryPoolData->first), validation_error_map[VALIDATION_ERROR_1b2000d0]);
+ skip |=
+ log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT,
+ VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, HandleToUint64(pCB->commandBuffer), __LINE__,
+ VALIDATION_ERROR_1b2000d0, "DS", "vkCmdExecuteCommands() called w/ invalid Cmd Buffer 0x%" PRIx64
+ " which has invalid active query pool 0x%" PRIx64
+ ". Pipeline statistics is being queried so the command "
+ "buffer must have all bits set on the queryPool. %s",
+ HandleToUint64(pCB->commandBuffer), HandleToUint64(queryPoolData->first),
+ validation_error_map[VALIDATION_ERROR_1b2000d0]);
}
}
activeTypes.insert(queryPoolData->second.createInfo.queryType);
if (queryPoolData != dev_data->queryPoolMap.end() && activeTypes.count(queryPoolData->second.createInfo.queryType)) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(pCB->commandBuffer), __LINE__, DRAWSTATE_INVALID_SECONDARY_COMMAND_BUFFER, "DS",
- "vkCmdExecuteCommands() called w/ invalid Cmd Buffer 0x%p "
- "which has invalid active query pool 0x%" PRIx64
- "of type %d but a query of that type has been started on "
- "secondary Cmd Buffer 0x%p.",
- pCB->commandBuffer, HandleToUint64(queryPoolData->first), queryPoolData->second.createInfo.queryType,
- pSubCB->commandBuffer);
+ "vkCmdExecuteCommands() called w/ invalid Cmd Buffer 0x%" PRIx64
+ " which has invalid active query pool 0x%" PRIx64
+ " of type %d but a query of that type has been started on "
+ "secondary Cmd Buffer 0x%" PRIx64 ".",
+ HandleToUint64(pCB->commandBuffer), HandleToUint64(queryPoolData->first),
+ queryPoolData->second.createInfo.queryType, HandleToUint64(pSubCB->commandBuffer));
}
}
auto primary_pool = GetCommandPoolNode(dev_data, pCB->createInfo.commandPool);
auto secondary_pool = GetCommandPoolNode(dev_data, pSubCB->createInfo.commandPool);
if (primary_pool && secondary_pool && (primary_pool->queueFamilyIndex != secondary_pool->queueFamilyIndex)) {
- skip |=
- log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
- HandleToUint64(pSubCB->commandBuffer), __LINE__, DRAWSTATE_INVALID_QUEUE_FAMILY, "DS",
- "vkCmdExecuteCommands(): Primary command buffer 0x%p"
- " created in queue family %d has secondary command buffer 0x%p created in queue family %d.",
- pCB->commandBuffer, primary_pool->queueFamilyIndex, pSubCB->commandBuffer, secondary_pool->queueFamilyIndex);
+ skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
+ HandleToUint64(pSubCB->commandBuffer), __LINE__, DRAWSTATE_INVALID_QUEUE_FAMILY, "DS",
+ "vkCmdExecuteCommands(): Primary command buffer 0x%" PRIx64
+ " created in queue family %d has secondary command buffer 0x%" PRIx64 " created in queue family %d.",
+ HandleToUint64(pCB->commandBuffer), primary_pool->queueFamilyIndex, HandleToUint64(pSubCB->commandBuffer),
+ secondary_pool->queueFamilyIndex);
}
return skip;
skip |=
log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(pCommandBuffers[i]), __LINE__, VALIDATION_ERROR_1b2000b0, "DS",
- "vkCmdExecuteCommands() called w/ Primary Cmd Buffer 0x%p in element %u of pCommandBuffers "
+ "vkCmdExecuteCommands() called w/ Primary Cmd Buffer 0x%" PRIx64
+ " in element %u of pCommandBuffers "
"array. All cmd buffers in pCommandBuffers array must be secondary. %s",
- pCommandBuffers[i], i, validation_error_map[VALIDATION_ERROR_1b2000b0]);
+ HandleToUint64(pCommandBuffers[i]), i, validation_error_map[VALIDATION_ERROR_1b2000b0]);
} else if (pCB->activeRenderPass) { // Secondary CB w/i RenderPass must have *CONTINUE_BIT set
if (pSubCB->beginInfo.pInheritanceInfo != nullptr) {
auto secondary_rp_state = GetRenderPassState(dev_data, pSubCB->beginInfo.pInheritanceInfo->renderPass);
skip |= log_msg(
dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(pCommandBuffers[i]), __LINE__, VALIDATION_ERROR_1b2000c0, "DS",
- "vkCmdExecuteCommands(): Secondary Command Buffer (0x%p) executed within render pass (0x%" PRIxLEAST64
+ "vkCmdExecuteCommands(): Secondary Command Buffer (0x%" PRIx64
+ ") executed within render pass (0x%" PRIx64
") must have had vkBeginCommandBuffer() called w/ VK_COMMAND_BUFFER_USAGE_RENDER_PASS_CONTINUE_BIT "
"set. %s",
- pCommandBuffers[i], HandleToUint64(pCB->activeRenderPass->renderPass),
+ HandleToUint64(pCommandBuffers[i]), HandleToUint64(pCB->activeRenderPass->renderPass),
validation_error_map[VALIDATION_ERROR_1b2000c0]);
} else {
// Make sure render pass is compatible with parent command buffer pass if has continue
skip |= validateCommandBufferState(dev_data, pSubCB, "vkCmdExecuteCommands()", 0, VALIDATION_ERROR_1b2000b2);
if (!(pSubCB->beginInfo.flags & VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT)) {
if (pSubCB->in_use.load() || pCB->linkedCommandBuffers.count(pSubCB)) {
- skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT,
- VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, HandleToUint64(pCB->commandBuffer), __LINE__,
- VALIDATION_ERROR_1b2000b4, "DS",
- "Attempt to simultaneously execute command buffer 0x%p"
- " without VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT set! %s",
- pCB->commandBuffer, validation_error_map[VALIDATION_ERROR_1b2000b4]);
+ skip |=
+ log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT,
+ VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, HandleToUint64(pCB->commandBuffer), __LINE__,
+ VALIDATION_ERROR_1b2000b4, "DS", "Attempt to simultaneously execute command buffer 0x%" PRIx64
+ " without VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT set! %s",
+ HandleToUint64(pCB->commandBuffer), validation_error_map[VALIDATION_ERROR_1b2000b4]);
}
if (pCB->beginInfo.flags & VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT) {
// Warn that non-simultaneous secondary cmd buffer renders primary non-simultaneous
skip |= log_msg(
dev_data->report_data, VK_DEBUG_REPORT_WARNING_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(pCommandBuffers[i]), __LINE__, DRAWSTATE_INVALID_CB_SIMULTANEOUS_USE, "DS",
- "vkCmdExecuteCommands(): Secondary Command Buffer (0x%p) "
+ "vkCmdExecuteCommands(): Secondary Command Buffer (0x%" PRIx64
+ ") "
"does not have VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT set and will cause primary command buffer "
- "(0x%p) to be treated as if it does not have VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT "
+ "(0x%" PRIx64
+ ") to be treated as if it does not have VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT "
"set, even though it does.",
- pCommandBuffers[i], pCB->commandBuffer);
+ HandleToUint64(pCommandBuffers[i]), HandleToUint64(pCB->commandBuffer));
pCB->beginInfo.flags &= ~VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT;
}
}
log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT,
HandleToUint64(pCommandBuffers[i]), __LINE__, VALIDATION_ERROR_1b2000ca, "DS",
"vkCmdExecuteCommands(): Secondary Command Buffer "
- "(0x%p) cannot be submitted with a query in "
+ "(0x%" PRIx64
+ ") cannot be submitted with a query in "
"flight and inherited queries not "
"supported on this device. %s",
- pCommandBuffers[i], validation_error_map[VALIDATION_ERROR_1b2000ca]);
+ HandleToUint64(pCommandBuffers[i]), validation_error_map[VALIDATION_ERROR_1b2000ca]);
}
// TODO: separate validate from update! This is very tangled.
// Propagate layout transitions to the primary cmd buffer
VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT) == 0) {
skip = log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DEVICE_MEMORY_EXT,
HandleToUint64(mem), __LINE__, VALIDATION_ERROR_31200554, "MEM",
- "Mapping Memory without VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT set: mem obj 0x%" PRIxLEAST64 ". %s",
+ "Mapping Memory without VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT set: mem obj 0x%" PRIx64 ". %s",
HandleToUint64(mem), validation_error_map[VALIDATION_ERROR_31200554]);
}
}
skip |= log_msg(
dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DEVICE_MEMORY_EXT,
HandleToUint64(mem_ranges[i].memory), __LINE__, MEMTRACK_INVALID_MAP, "MEM",
- "Memory underflow was detected on mem obj 0x%" PRIxLEAST64, HandleToUint64(mem_ranges[i].memory));
+ "Memory underflow was detected on mem obj 0x%" PRIx64, HandleToUint64(mem_ranges[i].memory));
}
}
for (uint64_t j = (size + mem_info->shadow_pad_size); j < (2 * mem_info->shadow_pad_size + size); ++j) {
if (data[j] != NoncoherentMemoryFillValue) {
- skip |= log_msg(
- dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DEVICE_MEMORY_EXT,
- HandleToUint64(mem_ranges[i].memory), __LINE__, MEMTRACK_INVALID_MAP, "MEM",
- "Memory overflow was detected on mem obj 0x%" PRIxLEAST64, HandleToUint64(mem_ranges[i].memory));
+ skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT,
+ VK_DEBUG_REPORT_OBJECT_TYPE_DEVICE_MEMORY_EXT, HandleToUint64(mem_ranges[i].memory),
+ __LINE__, MEMTRACK_INVALID_MAP, "MEM", "Memory overflow was detected on mem obj 0x%" PRIx64,
+ HandleToUint64(mem_ranges[i].memory));
}
}
memcpy(mem_info->p_driver_data, static_cast<void *>(data + mem_info->shadow_pad_size), (size_t)(size));
// vkGetImageMemoryRequirements()
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_WARNING_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT,
image_handle, __LINE__, DRAWSTATE_INVALID_IMAGE, "DS",
- "vkBindImageMemory(): Binding memory to image 0x%" PRIxLEAST64
+ "vkBindImageMemory(): Binding memory to image 0x%" PRIx64
" but vkGetImageMemoryRequirements() has not been called on that image.",
- image_handle);
+ HandleToUint64(image_handle));
// Make the call for them so we can verify the state
lock.unlock();
dev_data->dispatch_table.GetImageMemoryRequirements(dev_data->device, image, &image_state->requirements);
if (event_state->write_in_use) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_EVENT_EXT,
HandleToUint64(event), __LINE__, DRAWSTATE_QUEUE_FORWARD_PROGRESS, "DS",
- "Cannot call vkSetEvent() on event 0x%" PRIxLEAST64 " that is already in use by a command buffer.",
+ "Cannot call vkSetEvent() on event 0x%" PRIx64 " that is already in use by a command buffer.",
HandleToUint64(event));
}
}
(!(signaled_semaphores.count(semaphore)) && !(pSemaphore->signaled))) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_SEMAPHORE_EXT,
HandleToUint64(semaphore), __LINE__, DRAWSTATE_QUEUE_FORWARD_PROGRESS, "DS",
- "Queue 0x%p is waiting on semaphore 0x%" PRIx64 " that has no way to be signaled.", queue,
- HandleToUint64(semaphore));
+ "Queue 0x%" PRIx64 " is waiting on semaphore 0x%" PRIx64 " that has no way to be signaled.",
+ HandleToUint64(queue), HandleToUint64(semaphore));
} else {
signaled_semaphores.erase(semaphore);
unsignaled_semaphores.insert(semaphore);
if (signaled_semaphores.count(semaphore) || (!(unsignaled_semaphores.count(semaphore)) && pSemaphore->signaled)) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_SEMAPHORE_EXT,
HandleToUint64(semaphore), __LINE__, DRAWSTATE_QUEUE_FORWARD_PROGRESS, "DS",
- "Queue 0x%p is signaling semaphore 0x%" PRIx64
+ "Queue 0x%" PRIx64 " is signaling semaphore 0x%" PRIx64
" that has already been signaled but not waited on by queue 0x%" PRIx64 ".",
- queue, HandleToUint64(semaphore), HandleToUint64(pSemaphore->signaler.first));
+ HandleToUint64(queue), HandleToUint64(semaphore), HandleToUint64(pSemaphore->signaler.first));
} else {
unsignaled_semaphores.erase(semaphore);
signaled_semaphores.insert(semaphore);
return true;
} else if (pCreateInfo->minImageCount != 1) {
if (log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DEVICE_EXT,
- reinterpret_cast<uint64_t>(dev_data->device), __LINE__, VALIDATION_ERROR_14600ace, "DS",
+ HandleToUint64(dev_data->device), __LINE__, VALIDATION_ERROR_14600ace, "DS",
"%s called with presentMode %s, but minImageCount value is %d. For shared presentable image, minImageCount "
"must be 1. %s",
func_name, string_VkPresentModeKHR(pCreateInfo->presentMode), pCreateInfo->minImageCount,
if (pSemaphore && !pSemaphore->signaled) {
skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, 0,
__LINE__, DRAWSTATE_QUEUE_FORWARD_PROGRESS, "DS",
- "Queue 0x%p is waiting on semaphore 0x%" PRIx64 " that has no way to be signaled.", queue,
- HandleToUint64(pPresentInfo->pWaitSemaphores[i]));
+ "Queue 0x%" PRIx64 " is waiting on semaphore 0x%" PRIx64 " that has no way to be signaled.",
+ HandleToUint64(queue), HandleToUint64(pPresentInfo->pWaitSemaphores[i]));
}
}
} else {
log_msg(instance_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_INSTANCE_EXT, 0, __LINE__,
DEVLIMITS_INVALID_INSTANCE, "DL",
- "Invalid instance (0x%" PRIxLEAST64 ") passed into vkEnumeratePhysicalDeviceGroupsKHX().",
- HandleToUint64(instance));
+ "Invalid instance (0x%" PRIx64 ") passed into vkEnumeratePhysicalDeviceGroupsKHX().", HandleToUint64(instance));
}
return VK_ERROR_VALIDATION_FAILED_EXT;
}