-
-
Notifications
You must be signed in to change notification settings - Fork 33.8k
gh-134584: Eliminate redundant refcounting from _CALL_BUILTION_O
#136056
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 3 commits
3eec46d
6462322
bf66bce
e0773ea
0afcb51
a4f4225
0387a8e
04e3670
9346e22
0cde70b
fb65552
b484c32
c490ffb
71126ab
5f35702
e1f1df4
fee7782
369ce2b
dc62b62
da1d468
d07d3a3
e6174ee
226011b
f445c45
202fce0
a89ee4b
9f2a34a
33efd71
8c33c61
d7f0214
27f62eb
2ea67ca
c359ea4
2ff8608
2c1fdf3
9dbf77b
9ac1428
bc9e63d
7fe1a18
83d8134
d5d9e89
9c4ff8a
e02801d
69f54ce
656a64b
5ec03cf
3001464
5a7c9c6
fa9519f
d2d2e92
526d7a8
cc6bc4c
923056b
5b1862b
5e749d3
440bcb9
890fe5a
cfcd524
3c11738
7739943
f2ca158
db098a4
ea51e74
056d6c5
cd4d0ae
229ed3d
981ce0c
3e2c557
b708485
d4fa707
5a4c4a0
694922c
52f9b5f
f87eb4d
e32c975
eb89286
4172885
5e58548
2dc28eb
fddc24e
748c4b4
d3c888b
8801c6d
08d8e18
88cd5d9
4172644
7e5fcae
f6f456f
aea5531
62423c9
c0c6514
618dc36
547d8da
c525204
1a7824a
fb404ab
6825d5c
8392095
2dac9e6
b3bf212
128d316
53ec7c8
4238a97
cac4b04
1d8f3ed
706fdda
100c726
4b14529
4085ff7
59f247e
dcac498
58e1c7a
d49e6f3
eba449a
d119443
61823a5
5be3405
70c27ce
0ed56ed
35142b1
56a442d
14715e3
c91c373
100e316
07eff89
ed4f78a
9d707d8
332da62
572c780
edff5aa
c5b3722
d6d850d
1db9f56
f193c8f
dc9f238
ff2577f
ef51a7c
3fa1425
7099af8
3db7bf2
8620d30
c279e95
0b8c348
e3539e9
c4ccaf4
9d39c02
f2fba4c
37988c5
e0451ce
97f0a1f
9e3d7cd
80c2c2d
719d796
726e8e8
756e7d1
3ec941b
c5825ff
8914148
4279785
02c085d
bcb6cbd
49207a5
1b460fc
b20722c
1adb17b
bcf90de
09d6bf2
9b4ce3c
b5576d8
7f497c3
9188483
37fe9a9
d716e3b
7067126
49b1fb4
c0d0f4b
2db9573
c76cfe8
785268f
4629567
ebf3427
26757d1
97e1901
dc3ece2
880a790
fa44845
5b19c75
b52e8ce
0dd8311
da8199f
42d2bed
80c9756
469f191
4eab90f
79aa43a
44d3dc6
a78f43b
c433986
a275385
8cfa351
ffc7172
387f88c
dac4589
a26c831
af18572
e38967e
6a0135a
9fe6e3e
0a62f82
2eca80f
b1c9582
1356fbe
3b38388
519bee4
2a820e2
af2b3e9
be5e0dc
7aa353c
e0bca09
a3a611b
f564654
340a684
15313dd
6d644e4
40ac3a9
1eddef8
fa1ac90
8b669d5
57db125
0a97941
c90863a
3e36d37
c98182b
e02a35c
170dac2
c865ab3
123bbfd
ff52e90
f6b6a99
87e152d
e5a4848
6cddf04
2eb9537
52daab1
f893e8f
6ffa499
93b844f
9c4e2d6
5e752fc
3a19237
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| Eliminate redundant refcounting from ``_CALL_BUILTIN_O``. |
| Original file line number | Diff line number | Diff line change | ||||||
|---|---|---|---|---|---|---|---|---|
|
|
@@ -4202,7 +4202,7 @@ dummy_func( | |||||||
| _CALL_BUILTIN_CLASS + | ||||||||
| _CHECK_PERIODIC; | ||||||||
|
|
||||||||
| op(_CALL_BUILTIN_O, (callable, self_or_null, args[oparg] -- res)) { | ||||||||
| op(_CALL_BUILTIN_O, (callable, self_or_null, args[oparg] -- res, a, c)) { | ||||||||
| /* Builtin METH_O functions */ | ||||||||
| PyObject *callable_o = PyStackRef_AsPyObjectBorrow(callable); | ||||||||
|
|
||||||||
|
|
@@ -4222,11 +4222,9 @@ dummy_func( | |||||||
| PyObject *res_o = _PyCFunction_TrampolineCall(cfunc, PyCFunction_GET_SELF(callable_o), PyStackRef_AsPyObjectBorrow(arg)); | ||||||||
| _Py_LeaveRecursiveCallTstate(tstate); | ||||||||
| assert((res_o != NULL) ^ (_PyErr_Occurred(tstate) != NULL)); | ||||||||
|
|
||||||||
| PyStackRef_CLOSE(arg); | ||||||||
| DEAD(args); | ||||||||
| DEAD(self_or_null); | ||||||||
| PyStackRef_CLOSE(callable); | ||||||||
| INPUTS_DEAD(); | ||||||||
| a = arg; | ||||||||
| c = callable; | ||||||||
| ERROR_IF(res_o == NULL); | ||||||||
| res = PyStackRef_FromPyObjectSteal(res_o); | ||||||||
| } | ||||||||
|
|
@@ -4235,6 +4233,7 @@ dummy_func( | |||||||
| unused/1 + | ||||||||
| unused/2 + | ||||||||
| _CALL_BUILTIN_O + | ||||||||
| _POP_TWO + | ||||||||
|
||||||||
| _POP_TWO + | |
| POP_TOP + | |
| POP_TOP + |
The reason is that it's easier to optimize this way.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.