<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Tue, Jun 19, 2018 at 10:31 PM, Keith Packard <span dir="ltr"><<a href="mailto:keithp@keithp.com" target="_blank">keithp@keithp.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">Jason Ekstrand <<a href="mailto:jason@jlekstrand.net">jason@jlekstrand.net</a>> writes:<br>
<br>
>> + if (allocator)<br>
>> + alloc = allocator;<br>
>> + else<br>
>> + alloc = &device->instance->alloc;<br>
>><br>
><br>
> This is what vk_alloc2 is for. :-)<br>
</span>...<br>
> And vk_free2<br>
...<br>
<span class="">> This isn't needed if you're using vk_alloc2<br>
<br>
</span>Yeah, but I need to pass the allocator down to the wsi common code, and<br>
that doesn't have any way to touch the device driver allocator<br>
pointer. I bet I'm just missing something here. Help?<span class=""><br></span></blockquote><div><br></div><div>I believe that the WSI common code should be capable of fishing the instance allocator out of the wsi_display so we need only pass the allocator argument unmodified through to the core WSI code. Make sense? Yeah, Vulkan allocator fishing is weird.<br></div><div><br></div><div>--Jason<br></div></div></div></div>