You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
f"Expected {N_LOOPS} distinct lines on {stem}, got {line.n_mallocs} on line {LOOP_ALLOC_LINENO}"
85
+
)
86
+
87
+
bt_stem, bt_prof=below_threshold
88
+
bt_line=get_line(bt_prof, LOOP_ALLOC_LINENO)
89
+
ifnotbt_line.n_mallocs<N_LOOPS:
90
+
errors.append(
91
+
f"{bt_stem} makes smaller allocations than the allocation sampling window, so fewer than {N_LOOPS} allocations on {LOOP_ALLOC_LINENO} should be reported. Got {bt_line.n_mallocs} mallocs"
92
+
)
93
+
94
+
forstem, profilein [
95
+
one_alloc,
96
+
two_on_one_line,
97
+
below_threshold,
98
+
line_after_final_alloc,
99
+
]:
100
+
line=get_line(profile, OUT_OF_LOOP_ALLOC_LINENO)
101
+
ifnotline.n_mallocs==1:
102
+
errors.append(
103
+
f"Line {OUT_OF_LOOP_ALLOC_LINENO} in {stem} makes a large allocation, so it should be reported."
0 commit comments