From 411b1692811b2ecac59cb0df0f920861c7cf179a Mon Sep 17 00:00:00 2001 From: Mark Shannon Date: Wed, 12 Apr 2023 12:04:55 +0100 Subject: GH-103082: Implementation of PEP 669: Low Impact Monitoring for CPython (GH-103083) * The majority of the monitoring code is in instrumentation.c * The new instrumentation bytecodes are in bytecodes.c * legacy_tracing.c adapts the new API to the old sys.setrace and sys.setprofile APIs --- Lib/test/test__opcode.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Lib/test/test__opcode.py') diff --git a/Lib/test/test__opcode.py b/Lib/test/test__opcode.py index 31f3c53992d..7640c6fb57d 100644 --- a/Lib/test/test__opcode.py +++ b/Lib/test/test__opcode.py @@ -20,6 +20,8 @@ class OpcodeTests(unittest.TestCase): # All defined opcodes has_arg = dis.hasarg for name, code in filter(lambda item: item[0] not in dis.deoptmap, dis.opmap.items()): + if code >= opcode.MIN_INSTRUMENTED_OPCODE: + continue with self.subTest(opname=name): if code not in has_arg: stack_effect(code) @@ -47,6 +49,8 @@ class OpcodeTests(unittest.TestCase): has_exc = dis.hasexc has_jump = dis.hasjabs + dis.hasjrel for name, code in filter(lambda item: item[0] not in dis.deoptmap, dis.opmap.items()): + if code >= opcode.MIN_INSTRUMENTED_OPCODE: + continue with self.subTest(opname=name): if code not in has_arg: common = stack_effect(code) -- cgit v1.2.3