Author: Maciej Fijalkowski <[email protected]>
Branch: vmprof
Changeset: r76723:9efba357dd88
Date: 2015-04-06 15:22 +0200
http://bitbucket.org/pypy/pypy/changeset/9efba357dd88/

Log:    strip the topmost part of the code, with rationale

diff --git a/pypy/module/_vmprof/src/get_custom_offset.c 
b/pypy/module/_vmprof/src/get_custom_offset.c
--- a/pypy/module/_vmprof/src/get_custom_offset.c
+++ b/pypy/module/_vmprof/src/get_custom_offset.c
@@ -48,6 +48,12 @@
             break;
         result[n++] = (void *)id;
     }
+    // we strip the topmost part - the reason is that it's either
+    // represented in the jitted caller or it's not jitted (we have the
+    // same function essentially twice
+    if (n != max_depth) {
+        n--;
+    }
     k = 0;
     while (k < (n - start) / 2) {
         tmp = result[start + k];
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to