[compiler-rt] change write order of frexpl & frexpf so it doesn't corrupt stack ids
authorEmily Shi <code@emi.sh>
Fri, 25 Jun 2021 20:32:03 +0000 (13:32 -0700)
committerEmily Shi <code@emi.sh>
Fri, 16 Jul 2021 17:58:12 +0000 (10:58 -0700)
commitcfa4d112da8da97480c3018c68389aa06cb3efb8
tree08c95b675c191fa60be9861a3bb39387dd271a05
parent5c57600b934ac9b64cd557b90560de7d9df66a1d
[compiler-rt] change write order of frexpl & frexpf so it doesn't corrupt stack ids

This was fixed in the past for `frexp`, but was not made for `frexpl` & `frexpf` https://github.com/google/sanitizers/issues/321
This patch copies the fix over to `frexpl` because it caused `frexp_interceptor.cpp` test to fail on iPhone and `frexpf` for consistency.

rdar://79652161

Reviewed By: delcypher, vitalybuka

Differential Revision: https://reviews.llvm.org/D104948
compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors.inc
compiler-rt/test/asan/TestCases/frexpf_interceptor.cpp [new file with mode: 0644]
compiler-rt/test/asan/TestCases/frexpl_interceptor.cpp [new file with mode: 0644]