Skip to content
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

Refine specialization stats #27992

Merged
merged 9 commits into from
Aug 27, 2021
Merged

Conversation

markshannon
Copy link
Member

Some refinements to stats gathering, to give better information on LOAD_METHOD and BINARY_SUBSCR.
Records specialization failures for LOAD_METHOD along the lines of LOAD_ATTR
Records specialization failures for BINARY_SUBSCR for array.array, buffers and sequences.

Example output:

binary_add:
    deferred:    63280120 4.2%
       deopt:       34627 0.0%
         hit:  1451688590 95.2%
        miss:     8435234 0.6%
 unquickened:      819581 0.1%
  specialization_success:      134823
  specialization_failure:      965819
    kind  0:   917606 95.0%
    kind 12:    48213 5.0%
binary_subscr:
    deferred:  1281773440 47.6%
       deopt:      642679 0.0%
         hit:  1405555579 52.2%
        miss:     1930850 0.1%
 unquickened:     2043546 0.1%
  specialization_success:      895051
  specialization_failure:    19479515
    kind  0:  1200166 6.2%
    kind  8: 10149184 52.1%
    kind 10:  3545461 18.2%
    kind 11:    74440 0.4%
    kind 12:   375845 1.9%
    kind 13:   340340 1.7%
    kind 15:  3230249 16.6%
    kind 16:   555191 2.9%
    kind 17:     8639 0.0%
load_attr:
    deferred:   643223571 15.0%
       deopt:     1513796 0.0%
         hit:  3557197723 83.2%
        miss:    59242750 1.4%
 unquickened:    16235401 0.4%
  specialization_success:      958781
  specialization_failure:    10212363
    kind  0:     2691 0.0%
    kind  1:     3443 0.0%
    kind  2:  2871534 28.1%
    kind  4:  1726860 16.9%
    kind  5:     1323 0.0%
    kind  7:     7685 0.1%
    kind  8:  1780981 17.4%
    kind 10:   941129 9.2%
    kind 11:   586772 5.7%
    kind 12:   164496 1.6%
    kind 13:   670503 6.6%
    kind 14:   272718 2.7%
    kind 19:      258 0.0%
load_global:
    deferred:    11827512 0.4%
       deopt:      416422 0.0%
         hit:  2696769517 98.0%
        miss:     2738532 0.1%
 unquickened:    39136004 1.4%
  specialization_success:     2254536
  specialization_failure:           0
load_method:
    deferred:   194385279 10.1%
       deopt:     1324245 0.1%
         hit:  1672417959 86.8%
        miss:    28534267 1.5%
 unquickened:    31750112 1.6%
  specialization_success:     2085745
  specialization_failure:     1785798
    kind  3:   100911 5.7%
    kind  4:     9032 0.5%
    kind  5:   967191 54.2%
    kind  7:     1577 0.1%
    kind  9:    38382 2.1%
    kind 10:   209257 11.7%
    kind 15:    17588 1.0%
    kind 17:    18533 1.0%
    kind 18:   246072 13.8%
store_attr:
    deferred:    47920825 6.3%
       deopt:      117216 0.0%
         hit:   698996013 92.1%
        miss:     8449404 1.1%
 unquickened:     3692617 0.5%
  specialization_success:       67206
  specialization_failure:     1072906
    kind  1:    26408 2.5%
    kind  2:   110260 10.3%
    kind  4:   380920 35.5%
    kind  8:   161509 15.1%
    kind 11:    27273 2.5%
    kind 12:    18699 1.7%
    kind 13:     1355 0.1%
    kind 14:     9929 0.9%

@markshannon markshannon merged commit ee9c052 into python:main Aug 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants