Пример #1
0
 public final void compile() {
   if (!isCompiling()) {
     ensureCloned();
     runtime.compile(
         this,
         TruffleBackgroundCompilation.getValue()
             && !TruffleCompilationExceptionsAreThrown.getValue());
   }
 }
Пример #2
0
 public OptimizedCallTarget cloneUninitialized() {
   ensureCloned();
   RootNode copiedRoot = cloneRootNode(uninitializedRootNode);
   if (copiedRoot == null) {
     return null;
   }
   OptimizedCallTarget splitTarget =
       (OptimizedCallTarget) runtime.createClonedCallTarget(this, copiedRoot);
   splitTarget.cloneIndex = cloneIndex++;
   return splitTarget;
 }
Пример #3
0
 private void interpreterCall() {
   if (isValid()) {
     // Stubs were deoptimized => reinstall.
     this.runtime.reinstallStubs();
   } else {
     if (uninitializedRootNode == UNINITIALIZED) {
       ensureCloned();
     }
     compilationProfile.reportInterpreterCall();
     if (!isCompiling()
         && compilationPolicy.shouldCompile(compilationProfile, getCompilerOptions())) {
       compile();
     }
   }
 }