Only collect stacktraces at scalar Kr boundaries at history level 1.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10621 a5019735-40e9-0310-863c-91ae7b9d1cf9
diff --git a/helgrind/libhb_core.c b/helgrind/libhb_core.c
index b509401..58b5c6a 100644
--- a/helgrind/libhb_core.c
+++ b/helgrind/libhb_core.c
@@ -2885,6 +2885,11 @@
Word nPresent;
ULong_n_EC pair;
tl_assert(thr);
+
+ // We only collect this info at history level 1 (approx)
+ if (HG_(clo_history_level) != 1)
+ return;
+
/* This is the scalar Kr for thr. */
pair.ull = VtsID__indexAt( thr->viR, thr );
pair.ec = main_get_EC( thr );