Some implementation of SafeFetch, those not in assembly, are knowingly reading from arbitrary memory locations. ASan does not understand this, so it needs to be disabled for those functions. Additionally os::print_hex_dump is used to read memory locations from other stack frames and arbitrary memory locations. It guards the reads with os::is_readable_pointer. We also need to disable ASan for the section of os::print_hex_dump that reads from those locations.
Without this, under ASan, tests can fail and any crash which triggers os::print_hex_dump in the signal handler will crash itself.
Without this, under ASan, tests can fail and any crash which triggers os::print_hex_dump in the signal handler will crash itself.