[PATCH vkd3d 1/2] vkd3d: Add queries for KHR_timeline_semaphore extension.
Sveinar Søpler
cybermax at dexter.no
Sun Dec 15 08:57:18 CST 2019
On 13.12.2019 17:25, Sveinar Søpler wrote:
> On 12.12.2019 20:02, Rémi Bernon wrote:
>> +
>> + timeline_semaphore = &info->timeline_semaphore_properties;
>> + TRACE(" VkPhysicalDeviceTimelineSemaphorePropertiesKHR:\n");
>> + TRACE(" maxTimelineSemaphoreValueDifference: %u.\n",
>> timeline_semaphore->maxTimelineSemaphoreValueDifference);
>
> Should it be %lu? (Atleast seems to compile fine when changed to %lu.)
>
>
> libs/vkd3d/device.c:1039:11: warning: format ‘%u’ expects argument of
> type ‘unsigned int’, but argument 4 has type ‘uint64_t’ {aka ‘const
> long unsigned int’} [-Wformat=]
> 1039 | TRACE(" maxTimelineSemaphoreValueDifference: %u.\n",
> timeline_semaphore->maxTimelineSemaphoreValueDifference);
> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> | uint64_t {aka const long unsigned int}
>
>
Or rather it could be:
+
+ timeline_semaphore = &info->timeline_semaphore_properties;
+ TRACE(" VkPhysicalDeviceTimelineSemaphorePropertiesKHR:\n");
+ TRACE(" maxTimelineSemaphoreValueDifference: %" PRIu64 ".\n",
timeline_semaphore->maxTimelineSemaphoreValueDifference);
}
since it seems as "compile fine" was not correct for 32-bit... 64-bit
was fine with %lu, but 32-bit seems to want this to be %llu. For some
reason uint64_t is "long unsigned int" for 64-bit and "long long
unsigned int" for 32-bit for my compiler. Dunno if this is some weird
"ubuntu spesific" thing, or actually correct?
Sveinar
More information about the wine-devel
mailing list