Author: Armin Rigo <[email protected]>
Branch: vmprof-newstack
Changeset: r81778:63917019c08b
Date: 2016-01-15 09:51 +0100
http://bitbucket.org/pypy/pypy/changeset/63917019c08b/
Log: Write a warning if _continuation is imported when we call
_vmprof.enable()
diff --git a/pypy/module/_vmprof/interp_vmprof.py
b/pypy/module/_vmprof/interp_vmprof.py
--- a/pypy/module/_vmprof/interp_vmprof.py
+++ b/pypy/module/_vmprof/interp_vmprof.py
@@ -59,6 +59,11 @@
'interval' is a float representing the sampling interval, in seconds.
Must be smaller than 1.0
"""
+ w_modules = space.sys.get('modules')
+ if space.contains(w_modules, space.wrap('_continuation')):
+ space.warn(space.wrap("Using _continuation/greenlet/stacklet together "
+ "with vmprof will crash"),
+ space.w_RuntimeWarning)
try:
rvmprof.enable(fileno, period)
except rvmprof.VMProfError, e:
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit