Skip to content
Browse files
[Truffle] Options for inlining yield.
  • Loading branch information
chrisseaton committed Nov 1, 2014
1 parent 8434fe5 commit 45108cc
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
@@ -18,6 +18,7 @@
import org.jruby.truffle.nodes.RubyNode;
import org.jruby.truffle.runtime.*;
import org.jruby.truffle.runtime.core.*;
import org.jruby.util.cli.Options;

@NodeInfo(cost = NodeCost.POLYMORPHIC)
public class CachedYieldDispatchNode extends YieldDispatchNode {
@@ -31,11 +32,11 @@ public CachedYieldDispatchNode(RubyContext context, RubyProc block, YieldDispatc
callNode = Truffle.getRuntime().createDirectCallNode(block.getCallTarget());

if (callNode.isSplittable()) {
if (Options.TRUFFLE_INLINER_ALWAYS_CLONE_YIELD.load() && callNode.isSplittable()) {

if (callNode.isInlinable()) {
if (Options.TRUFFLE_INLINER_ALWAYS_INLINE_YIELD.load() && callNode.isInlinable()) {

@@ -148,6 +148,8 @@ public class Options {
public static final Option<Boolean> TRUFFLE_DEBUG_ENABLE_ASSERT_CONSTANT = bool(TRUFFLE, "truffle.debug.enable_assert_constant", false, "Enable special 'truffle_assert_constant' form.");
public static final Option<Boolean> TRUFFLE_CALL_FORCE_SPLIT_INLINE_MISSING = bool(TRUFFLE, "", true, "Force splitting/inlining of a method missing call.");
public static final Option<Boolean> TRUFFLE_PANIC_ON_JAVA_ASSERT = bool(TRUFFLE, "truffle.debug.panic_on_java_assert", false, "Panic as soon as a Java assertion failure is found.");
public static final Option<Boolean> TRUFFLE_INLINER_ALWAYS_CLONE_YIELD = bool(TRUFFLE, "truffle.inliner.always_clone_yield", true, "Always clone yield call targets.");
public static final Option<Boolean> TRUFFLE_INLINER_ALWAYS_INLINE_YIELD = bool(TRUFFLE, "truffle.inliner.always_inline_yield", true, "Always inline yield call targets.");

public static final Option<Boolean> NATIVE_ENABLED = bool(NATIVE, "native.enabled", true, "Enable/disable native code, including POSIX features and C exts.");
public static final Option<Boolean> NATIVE_VERBOSE = bool(NATIVE, "native.verbose", false, "Enable verbose logging of native extension loading.");

0 comments on commit 45108cc

Please sign in to comment.