Skip to content

Instantly share code, notes, and snippets.

@timo
Created April 5, 2018 09:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save timo/3203bb8b0d627527e8f8279e6af2a8bb to your computer and use it in GitHub Desktop.
Save timo/3203bb8b0d627527e8f8279e6af2a8bb to your computer and use it in GitHub Desktop.
diff --git a/src/spesh/candidate.c b/src/spesh/candidate.c
index 2d98c5adb..dd6da77e3 100644
--- a/src/spesh/candidate.c
+++ b/src/spesh/candidate.c
@@ -70,7 +70,7 @@ void MVM_spesh_candidate_add(MVMThreadContext *tc, MVMSpeshPlanned *p) {
#endif
p->should_retry = 1;
- if (tc->instance->spesh_log_fh)
+ /*if (tc->instance->spesh_log_fh)*/
fprintf(tc->instance->spesh_log_fh,
"Specialization bailed out due to %u unresolved WVals\n",
sg->sc_idx_resolve_used);
diff --git a/src/spesh/inline.c b/src/spesh/inline.c
index b4c3712a9..0ddc00bb0 100644
--- a/src/spesh/inline.c
+++ b/src/spesh/inline.c
@@ -237,6 +237,8 @@ static void fix_wval(MVMThreadContext *tc, MVMSpeshGraph *inliner,
inliner->sc_idx_to_resolve =
MVM_spesh_alloc(tc, inliner, 4 * sizeof(MVMuint64));
inliner->sc_idx_resolve_alloc = 4;
+ inliner->sc_idx_resolve_used = 0;
+ fprintf(stderr, "initialized an sc resolve array\n");
}
else if (inliner->sc_idx_resolve_used > inliner->sc_idx_resolve_alloc) {
MVMuint32 new_size = inliner->sc_idx_resolve_alloc * 2;
@@ -256,6 +258,7 @@ static void fix_wval(MVMThreadContext *tc, MVMSpeshGraph *inliner,
inliner->scs_to_resolve_from[inliner->sc_idx_resolve_used] = sc;
inliner->sc_idx_to_resolve[inliner->sc_idx_resolve_used] = idx;
inliner->sc_idx_resolve_used++;
+ fprintf(stderr, "resolve_used: %d\n", inliner->sc_idx_resolve_used);
}
}
else {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment