[PATCH vkd3d v3 4/5] vkd3d-shader: Use struct vkd3d_bytecode_buffer in vkd3d_shader_serialize_root_signature().

Henri Verbeet hverbeet at gmail.com
Wed Jul 7 04:17:09 CDT 2021


On Tue, 6 Jul 2021 at 21:12, Zebediah Figura (she/her)
<zfigura at codeweavers.com> wrote:
> The problem I see with the compiler error messages is that they
> universally try to allocate more memory than we just failed to allocate.

I don't think that's necessarily true. Both string buffers and byte
code buffers grow by doubling the existing allocation size; the amount
of memory they try to allocate is determined by the existing size, not
the amount of data we try to write to it. It's also very well possible
that the error message string buffer still has sufficient remaining
space to not require growing in order to write the message.
(Incidentally, it's not entirely inconceivable that future versions of
the API would support simply writing directly to stdin/stdout/stderr,
perhaps even by using custom input/output/error callbacks.)



More information about the wine-devel mailing list