Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[Truffle] Always split and inline yield.
  • Loading branch information
chrisseaton committed Oct 31, 2014
1 parent ca51c78 commit f2c36e6
Showing 1 changed file with 11 additions and 0 deletions.
Expand Up @@ -27,7 +27,18 @@ public class CachedYieldDispatchNode extends YieldDispatchNode {

public CachedYieldDispatchNode(RubyContext context, RubyProc block, YieldDispatchNode next) {
super(context);

callNode = Truffle.getRuntime().createDirectCallNode(block.getCallTarget());
insert(callNode);

if (callNode.isSplittable()) {
callNode.split();
}

if (callNode.isInlinable()) {
callNode.forceInlining();
}

this.next = next;
}

Expand Down

0 comments on commit f2c36e6

Please sign in to comment.