Skip to content

Instantly share code, notes, and snippets.

@jnthn
Created May 11, 2014 10:58
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 jnthn/19e017bca18c42a10c04 to your computer and use it in GitHub Desktop.
Save jnthn/19e017bca18c42a10c04 to your computer and use it in GitHub Desktop.
diff --git a/src/spesh/facts.c b/src/spesh/facts.c
index 470d203..85b2fd8 100644
--- a/src/spesh/facts.c
+++ b/src/spesh/facts.c
@@ -134,7 +134,8 @@ static void log_facts(MVMThreadContext *tc, MVMSpeshGraph *g, MVMSpeshIns *ins)
if (!stable_value) {
stable_value = consider;
}
- else if (STABLE(stable_value) != STABLE(consider)) {
+ else if (STABLE(stable_value) != STABLE(consider)
+ || IS_CONCRETE(stable_value) != IS_CONCRETE(consider)) {
stable_value = NULL;
break;
}
@@ -144,7 +145,7 @@ static void log_facts(MVMThreadContext *tc, MVMSpeshGraph *g, MVMSpeshIns *ins)
return;
/* If the value is a container type, need to look inside of it. */
- if (STABLE(stable_value)->container_spec) {
+ if (STABLE(stable_value)->container_spec && IS_CONCRETE(stable_value)) {
MVMContainerSpec const *contspec = STABLE(stable_value)->container_spec;
if (!contspec->fetch_never_invokes)
return;
@@ -157,7 +158,8 @@ static void log_facts(MVMThreadContext *tc, MVMSpeshGraph *g, MVMSpeshIns *ins)
if (!stable_value) {
stable_value = r.o;
}
- else if (STABLE(stable_value) != STABLE(r.o)) {
+ else if (STABLE(stable_value) != STABLE(r.o)
+ || IS_CONCRETE(stable_value) != IS_CONCRETE(r.o)) {
stable_value = NULL;
break;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment