[pypy-commit] pypy default: Windows fixes around vmprof
arigo
pypy.commits at gmail.com
Wed Oct 5 10:30:00 EDT 2016
Author: Armin Rigo <arigo at tunes.org>
Branch:
Changeset: r87589:93f59ce19b35
Date: 2016-10-05 16:28 +0200
http://bitbucket.org/pypy/pypy/changeset/93f59ce19b35/
Log: Windows fixes around vmprof
diff --git a/pypy/config/pypyoption.py b/pypy/config/pypyoption.py
--- a/pypy/config/pypyoption.py
+++ b/pypy/config/pypyoption.py
@@ -68,6 +68,8 @@
if "cppyy" in working_modules:
working_modules.remove("cppyy") # not tested on win32
+ if "faulthandler" in working_modules:
+ working_modules.remove("faulthandler") # missing details
# The _locale module is needed by site.py on Windows
default_modules.add("_locale")
diff --git a/rpython/rlib/rvmprof/src/rvmprof.h b/rpython/rlib/rvmprof/src/rvmprof.h
--- a/rpython/rlib/rvmprof/src/rvmprof.h
+++ b/rpython/rlib/rvmprof/src/rvmprof.h
@@ -1,4 +1,8 @@
-#include <stdint.h>
+#ifdef _WIN32
+typedef long intptr_t;
+#else
+# include <stdint.h>
+#endif
RPY_EXTERN char *vmprof_init(int, double, char *);
RPY_EXTERN void vmprof_ignore_signals(int);
diff --git a/rpython/rlib/rvmprof/src/vmprof_common.h b/rpython/rlib/rvmprof/src/vmprof_common.h
--- a/rpython/rlib/rvmprof/src/vmprof_common.h
+++ b/rpython/rlib/rvmprof/src/vmprof_common.h
@@ -134,7 +134,11 @@
intptr_t *result_p, intptr_t result_length)
{
int n;
+#ifdef _WIN32
+ intptr_t pc = 0; /* XXX implement me */
+#else
intptr_t pc = ucontext ? GetPC((ucontext_t *)ucontext) : 0;
+#endif
if (stack == NULL)
stack = get_vmprof_stack();
n = get_stack_trace(stack, result_p, result_length - 2, pc);
More information about the pypy-commit
mailing list