Revert "Zero-initialize Vec components to avoid MSan warnings"

This reverts commit 3d5625d23dd4573e9e85410da3cde1acc70773fe.

Reason for revert: Breaking GCC

../SRC/skia/src/base/SkUtils.h: In instantiation of 'T sk_unaligned_load(const P*) [with T = skvx::Vec<4, float>; P = __vector(4) float]':
../SRC/skia/src/base/SkUtils.h:65:34:   required from 'Dst sk_bit_cast(const Src&) [with Dst = skvx::Vec<4, float>; Src = __vector(4) float]'
../SRC/skia/src/base/SkVx.h:274:85:   required from here
../SRC/skia/src/base/SkUtils.h:49:11: error: 'void* memcpy(void*, const void*, size_t)' copying an object of non-trivial type 'struct skvx::Vec<4, float>' from an array of 'const __vector(4) float' [-Werror=class-memaccess]
   49 |     memcpy(&val, ptr, sizeof(val));

Original change's description:
> Zero-initialize Vec components to avoid MSan warnings
> MSan now implements stricter checks when passing uninitialized values in
> parameters or return values. The stricter checks catches code like
> SkMatrix::Affine_vpts(), which intentionally avoided initializing the
> hi float of the input float4, since it also ignored the hi float of the
> output float4.
> However, MSan detects this case now. Rather than allowing the default
> Vec<1, ...> constructor to intentionally leave the value uninitialized,
> explicitly zero initialize the value field instead. This transitively
> initializes lo/hi for all other Vec<N, ...> specializations.
> Bug: chromium:1369167
> Change-Id: Id3ed6a8cd1448e4a37a53a5deedcf8bddd4bb788
> Reviewed-on:
> Commit-Queue: Daniel Cheng <>
> Reviewed-by: Kevin Lubick <>
> Reviewed-by: Brian Osman <>

Bug: chromium:1369167
Change-Id: I8aed0a917ad5ad5866db58a62dee7a15f588c839
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Auto-Submit: Kevin Lubick <>
Bot-Commit: Rubber Stamper <>
1 file changed