summaryrefslogtreecommitdiff
path: root/src/ir/cost.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/ir/cost.h')
-rw-r--r--src/ir/cost.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/ir/cost.h b/src/ir/cost.h
index 821e46524..7a8776c00 100644
--- a/src/ir/cost.h
+++ b/src/ir/cost.h
@@ -726,6 +726,10 @@ struct CostAnalyzer : public OverriddenVisitor<CostAnalyzer, CostType> {
return 8 + visit(curr->ref) + visit(curr->num);
}
+ CostType visitContNew(ContNew* curr) {
+ // Some arbitrary "high" value, reflecting that this may allocate a stack
+ return 14 + visit(curr->func);
+ }
CostType visitResume(Resume* curr) {
// Inspired by indirect calls, but twice the cost.
return 12 + visit(curr->cont);