You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We improve initialization speed by avoiding unnecessary memsets and
transforming a for-loop to a memset. The two cases handled:
1. When int64_t(val) < 0, zeroing out is redundant as the subsequent
for-loop will initialize to val .. 0xFFFFF ..... Instead we should
only create an uninitialized buffer, and transform the slow for-loop
into a memset to initialize the higher words to 0xFF.
2. In the other case, first we create an uninitialized array (new
int64_t[]) and then we zero it out with memset. But this can be
combined in one operation with new int64_t[](), which
default-initializes the array.
0 commit comments