Generate tags for heap allocations from a pseudo-random sequence
seeded with getrandom(), where available.
Details
Details
Diff Detail
Diff Detail
- Build Status
Buildable 13485 Build 13485: arc lint + arc unit
Event Timeline
compiler-rt/lib/hwasan/hwasan_thread.cc | ||
---|---|---|
102 | GetRandom and xorshift can result in 0, right? Maybe this and drop CHECK: if (!random_buffer_) { random_state_ = xorshift(random_state_); while (!random_state) random_state = RandomSeed(); random_buffer_ = random_state_; } |
Comment Actions
avoid zero random seed
compiler-rt/lib/hwasan/hwasan_thread.cc | ||
---|---|---|
102 | Good point, RandomSeed can be zero, but xorshift, as far as i can see, will never turn non-zero to zero. Fixed with a loop in RandomSeed. |
GetRandom and xorshift can result in 0, right? Maybe this and drop CHECK: