diff options
author | Guido van Rossum <guido@python.org> | 2024-02-29 00:05:53 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-02-29 00:05:53 (GMT) |
commit | 86e5e063aba76a7f4fc58f7d06b17b0a4730fd8e (patch) | |
tree | c05481118366a7abea7bb2531b861ab3d7712622 /Tools | |
parent | 479ac5ce8a311c9a5830b96e972478867fcbce61 (diff) | |
download | cpython-86e5e063aba76a7f4fc58f7d06b17b0a4730fd8e.zip cpython-86e5e063aba76a7f4fc58f7d06b17b0a4730fd8e.tar.gz cpython-86e5e063aba76a7f4fc58f7d06b17b0a4730fd8e.tar.bz2 |
gh-115816: Generate calls to sym_new_const() etc. without _Py_uop prefix (#116077)
This was left behind by GH-115987. Basically a lot of diffs like this:
```
- res = _Py_uop_sym_new_unknown(ctx);
+ res = sym_new_unknown(ctx);
```
Diffstat (limited to 'Tools')
-rw-r--r-- | Tools/cases_generator/optimizer_generator.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Tools/cases_generator/optimizer_generator.py b/Tools/cases_generator/optimizer_generator.py index e933fee..d3ce4c8 100644 --- a/Tools/cases_generator/optimizer_generator.py +++ b/Tools/cases_generator/optimizer_generator.py @@ -28,7 +28,7 @@ from generators_common import ( from cwriter import CWriter from typing import TextIO, Iterator from lexer import Token -from stack import StackOffset, Stack, SizeMismatch, UNUSED +from stack import Stack, SizeMismatch, UNUSED DEFAULT_OUTPUT = ROOT / "Python/optimizer_cases.c.h" DEFAULT_ABSTRACT_INPUT = ROOT / "Python/optimizer_bytecodes.c" @@ -87,14 +87,14 @@ def emit_default(out: CWriter, uop: Uop) -> None: if var.name != "unused" and not var.peek: if var.is_array(): out.emit(f"for (int _i = {var.size}; --_i >= 0;) {{\n") - out.emit(f"{var.name}[_i] = _Py_uop_sym_new_unknown(ctx);\n") + out.emit(f"{var.name}[_i] = sym_new_unknown(ctx);\n") out.emit(f"if ({var.name}[_i] == NULL) goto out_of_space;\n") out.emit("}\n") elif var.name == "null": - out.emit(f"{var.name} = _Py_uop_sym_new_null(ctx);\n") + out.emit(f"{var.name} = sym_new_null(ctx);\n") out.emit(f"if ({var.name} == NULL) goto out_of_space;\n") else: - out.emit(f"{var.name} = _Py_uop_sym_new_unknown(ctx);\n") + out.emit(f"{var.name} = sym_new_unknown(ctx);\n") out.emit(f"if ({var.name} == NULL) goto out_of_space;\n") |