When length is 0, the code does nothing, so skip it completely.
Previously, os.Push(0) would do nothing as well. But with the newly added assertion, is the stack is empty, it will fail the assertion.
This commit is contained in:
parent
91a803d463
commit
95224aff7d
@ -948,11 +948,13 @@ private:
|
|||||||
#else
|
#else
|
||||||
length = static_cast<SizeType>(__builtin_ffs(r) - 1);
|
length = static_cast<SizeType>(__builtin_ffs(r) - 1);
|
||||||
#endif
|
#endif
|
||||||
|
if (length != 0) {
|
||||||
char* q = reinterpret_cast<char*>(os.Push(length));
|
char* q = reinterpret_cast<char*>(os.Push(length));
|
||||||
for (size_t i = 0; i < length; i++)
|
for (size_t i = 0; i < length; i++)
|
||||||
q[i] = p[i];
|
q[i] = p[i];
|
||||||
|
|
||||||
p += length;
|
p += length;
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
_mm_storeu_si128(reinterpret_cast<__m128i *>(os.Push(16)), s);
|
_mm_storeu_si128(reinterpret_cast<__m128i *>(os.Push(16)), s);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user