Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8302102

Disable ASan for SafeFetch and os::print_hex_dump

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P4 P4
    • 21
    • 21
    • hotspot
    • None
    • b10

      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.

            jcking Justin King
            jcking Justin King
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: