summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2013-07-03 20:35:39 (GMT)
committerVictor Stinner <victor.stinner@gmail.com>2013-07-03 20:35:39 (GMT)
commit647d1e1acd5e2b73e8e425df12dc8f2ba48e1583 (patch)
tree7b3c0e3a4e0c532e35cff0f636d7c3f88e13c24c /Lib
parentee31bc09cf7449963be9f3fc1f440cee85aeb2e7 (diff)
parent330426cfe268a3ccaaf2baa20e0d1d37b0312c40 (diff)
downloadcpython-647d1e1acd5e2b73e8e425df12dc8f2ba48e1583.zip
cpython-647d1e1acd5e2b73e8e425df12dc8f2ba48e1583.tar.gz
cpython-647d1e1acd5e2b73e8e425df12dc8f2ba48e1583.tar.bz2
(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.
Diffstat (limited to 'Lib')
-rw-r--r--Lib/test/test_faulthandler.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/test/test_faulthandler.py b/Lib/test/test_faulthandler.py
index 0eba284..4a8becf 100644
--- a/Lib/test/test_faulthandler.py
+++ b/Lib/test/test_faulthandler.py
@@ -107,6 +107,8 @@ class FaultHandlerTests(unittest.TestCase):
self.assertRegex(output, regex)
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):
self.check_fatal_error("""
import faulthandler