[PATCH 2/5] wined3d: Wrap resource->heapMemory into a structure

Henri Verbeet hverbeet at gmail.com
Mon Aug 19 07:34:31 CDT 2013


On 19 August 2013 14:20, Stefan Dösinger <stefandoesinger at gmail.com> wrote:
> Am 2013-08-19 13:53, schrieb Henri Verbeet:
>> That's actually a bug in what I posted.
> What's your suggested fix? Allocating size + align + alignment, and
> adding alignment to mem if mem happens to be already aligned?
>
I think it needs to be "align = max(sizeof(*p), alignment);", but
that's actually for the aligned + 1 case.

I think we can always add some extra padding in the caller if it turns
out to be needed, but I'm tempted to not worry too much about it,
since it could very well be that the original comment was actually
about alignment, and a regression test should give pretty obvious
results if this breaks something.



More information about the wine-devel mailing list