[Mesa-dev] [PATCH 2/2] i965: Guard GetBufferSubData's streaming memcpy load with USE_SSE41

Chris Wilson chris at chris-wilson.co.uk
Fri Aug 11 09:27:19 UTC 2017


Quoting Kenneth Graunke (2017-08-11 06:52:47)
> This should hopefully fix build issues on 32-bit Android-x86.
> 
> Cc: Mauro Rossi <issor.oruam at gmail.com>
> Cc: Tapani Pälli <tapani.palli at intel.com>
> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=102050
> ---
>  src/mesa/drivers/dri/i965/intel_buffer_objects.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> Mauro, hopefully this helps?

Which symbol isn't there? I presume cpu_has_sse4_1 is defined to 0 if
!USE_SSE4_1 and so we could do

#ifndef USE_SSE4_1
static inline void *_mesa_streaming_load_memcpy(void *dst, void *src, size_t size)
{
	unreachable("Illegal CPU");
}
#endif

The compiler should be quiet happy to do the dead-code elimination for
one less ifdef in the code. Worth it?
-Chris


More information about the mesa-dev mailing list