Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
76f7f4d9
Kaydet (Commit)
76f7f4d9
authored
Tem 18, 2011
tarafından
Benjamin Peterson
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
excise the remains of STOP_CODE, which hasn't done anything useful for years
üst
42d1320c
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
1 addition
and
13 deletions
+1
-13
dis.rst
Doc/library/dis.rst
+0
-5
opcode.h
Include/opcode.h
+0
-1
opcode.py
Lib/opcode.py
+0
-1
test_dis.py
Lib/test/test_dis.py
+1
-1
ceval.c
Python/ceval.c
+0
-2
makeopcodetargets.py
Python/makeopcodetargets.py
+0
-3
No files found.
Doc/library/dis.rst
Dosyayı görüntüle @
76f7f4d9
...
@@ -171,11 +171,6 @@ The Python compiler currently generates the following bytecode instructions.
...
@@ -171,11 +171,6 @@ The Python compiler currently generates the following bytecode instructions.
**General instructions**
**General instructions**
.. opcode:: STOP_CODE
Indicates end-of-code to the compiler, not used by the interpreter.
.. opcode:: NOP
.. opcode:: NOP
Do nothing code. Used as a placeholder by the bytecode optimizer.
Do nothing code. Used as a placeholder by the bytecode optimizer.
...
...
Include/opcode.h
Dosyayı görüntüle @
76f7f4d9
...
@@ -7,7 +7,6 @@ extern "C" {
...
@@ -7,7 +7,6 @@ extern "C" {
/* Instruction opcodes for compiled code */
/* Instruction opcodes for compiled code */
#define STOP_CODE 0
#define POP_TOP 1
#define POP_TOP 1
#define ROT_TWO 2
#define ROT_TWO 2
#define ROT_THREE 3
#define ROT_THREE 3
...
...
Lib/opcode.py
Dosyayı görüntüle @
76f7f4d9
...
@@ -43,7 +43,6 @@ def jabs_op(name, op):
...
@@ -43,7 +43,6 @@ def jabs_op(name, op):
# Instruction opcodes for compiled code
# Instruction opcodes for compiled code
# Blank lines correspond to available opcodes
# Blank lines correspond to available opcodes
def_op
(
'STOP_CODE'
,
0
)
def_op
(
'POP_TOP'
,
1
)
def_op
(
'POP_TOP'
,
1
)
def_op
(
'ROT_TWO'
,
2
)
def_op
(
'ROT_TWO'
,
2
)
def_op
(
'ROT_THREE'
,
3
)
def_op
(
'ROT_THREE'
,
3
)
...
...
Lib/test/test_dis.py
Dosyayı görüntüle @
76f7f4d9
...
@@ -200,7 +200,7 @@ class DisTests(unittest.TestCase):
...
@@ -200,7 +200,7 @@ class DisTests(unittest.TestCase):
lines
)))
lines
)))
def
test_opmap
(
self
):
def
test_opmap
(
self
):
self
.
assertEqual
(
dis
.
opmap
[
"
STOP_CODE"
],
0
)
self
.
assertEqual
(
dis
.
opmap
[
"
NOP"
],
9
)
self
.
assertIn
(
dis
.
opmap
[
"LOAD_CONST"
],
dis
.
hasconst
)
self
.
assertIn
(
dis
.
opmap
[
"LOAD_CONST"
],
dis
.
hasconst
)
self
.
assertIn
(
dis
.
opmap
[
"STORE_NAME"
],
dis
.
hasname
)
self
.
assertIn
(
dis
.
opmap
[
"STORE_NAME"
],
dis
.
hasname
)
...
...
Python/ceval.c
Dosyayı görüntüle @
76f7f4d9
...
@@ -1347,8 +1347,6 @@ PyEval_EvalFrameEx(PyFrameObject *f, int throwflag)
...
@@ -1347,8 +1347,6 @@ PyEval_EvalFrameEx(PyFrameObject *f, int throwflag)
x to NULL, err to nonzero, or why to anything but WHY_NOT,
x to NULL, err to nonzero, or why to anything but WHY_NOT,
and that no operation that succeeds does this! */
and that no operation that succeeds does this! */
/* case STOP_CODE: this is an error! */
TARGET
(
NOP
)
TARGET
(
NOP
)
FAST_DISPATCH
();
FAST_DISPATCH
();
...
...
Python/makeopcodetargets.py
Dosyayı görüntüle @
76f7f4d9
...
@@ -23,9 +23,6 @@ def write_contents(f):
...
@@ -23,9 +23,6 @@ def write_contents(f):
opcode
=
find_module
(
"opcode"
)
opcode
=
find_module
(
"opcode"
)
targets
=
[
'_unknown_opcode'
]
*
256
targets
=
[
'_unknown_opcode'
]
*
256
for
opname
,
op
in
opcode
.
opmap
.
items
():
for
opname
,
op
in
opcode
.
opmap
.
items
():
if
opname
==
"STOP_CODE"
:
# XXX opcode not implemented
continue
targets
[
op
]
=
"TARGET_
%
s"
%
opname
targets
[
op
]
=
"TARGET_
%
s"
%
opname
f
.
write
(
"static void *opcode_targets[256] = {
\n
"
)
f
.
write
(
"static void *opcode_targets[256] = {
\n
"
)
f
.
write
(
",
\n
"
.
join
([
" &&
%
s"
%
s
for
s
in
targets
]))
f
.
write
(
",
\n
"
.
join
([
" &&
%
s"
%
s
for
s
in
targets
]))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment