Interface TruffleCompilationTask


public interface TruffleCompilationTask
A handle to a compilation task managed by the Truffle runtime.
  • Method Summary

    Modifier and Type
    Method
    Description
    default void
    To be used from the compiler side.
    default void
    Records the given target to be dequeued from the compilation queue at the end of the current compilation.
    default Map<String,Object>
    getDebugProperties(jdk.vm.ci.meta.JavaConstant node)
    Returns the debug properties of a truffle node constant or an empty map if there are no debug properties.
    getPosition(jdk.vm.ci.meta.JavaConstant node)
    If node represents an AST Node then return the nearest source information for it.
    boolean
     
    boolean
    Determines if this compilation has been cancelled.
    default boolean
    Returns true if this is a first tier compilation.
    boolean
    Returns true if this is a last tier compilation.
    default void
    setCallCounts(int total, int inlined)
    To be used from the compiler side.
    default int
     
  • Method Details

    • isCancelled

      boolean isCancelled()
      Determines if this compilation has been cancelled.
    • isLastTier

      boolean isLastTier()
      Returns true if this is a last tier compilation.
    • isFirstTier

      default boolean isFirstTier()
      Returns true if this is a first tier compilation.
    • tier

      default int tier()
    • hasNextTier

      boolean hasNextTier()
    • getPosition

      default TruffleSourceLanguagePosition getPosition(jdk.vm.ci.meta.JavaConstant node)
      If node represents an AST Node then return the nearest source information for it. Otherwise simply return null.
    • getDebugProperties

      default Map<String,Object> getDebugProperties(jdk.vm.ci.meta.JavaConstant node)
      Returns the debug properties of a truffle node constant or an empty map if there are no debug properties.
    • addTargetToDequeue

      default void addTargetToDequeue(TruffleCompilable target)
      Records the given target to be dequeued from the compilation queue at the end of the current compilation.
    • setCallCounts

      default void setCallCounts(int total, int inlined)
      To be used from the compiler side. Sets how many calls in total are in the related compilation unit, and how many of those were inlined.
    • addInlinedTarget

      default void addInlinedTarget(TruffleCompilable target)
      To be used from the compiler side.
      Parameters:
      target - register this target as inlined.