Commit 647d1e1a authored by Victor Stinner's avatar Victor Stinner

(Merge 3.3) test_faulthandler: skip test_read_null() on AIX

AIX maps the first page of memory at address zero as valid, read-only.  Reading
NULL is not a fault on AIX. This is utilized by IBM compiler optimizations.
One speculatively can indirect through a pointer which may be null without
first testing if null and defer the test before using the value.
parents ee31bc09 330426cf
...@@ -107,6 +107,8 @@ class FaultHandlerTests(unittest.TestCase): ...@@ -107,6 +107,8 @@ class FaultHandlerTests(unittest.TestCase):
self.assertRegex(output, regex) self.assertRegex(output, regex)
self.assertNotEqual(exitcode, 0) self.assertNotEqual(exitcode, 0)
@unittest.skipIf(sys.platform.startswith('aix'),
"the first page of memory is a mapped read-only on AIX")
def test_read_null(self): def test_read_null(self):
self.check_fatal_error(""" self.check_fatal_error("""
import faulthandler import faulthandler
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment