/** * Call to create a new instance of a branch profile. * * @since 0.10 */ public static BranchProfile create() { if (Profile.isProfilingEnabled()) { return Enabled.create0(); } else { return Disabled.INSTANCE; } }
/** * Returns a value profile that profiles the exact value of an <code>long</code>. * * @see LongValueProfile * @since 0.10 */ public static LongValueProfile createIdentityProfile() { if (Profile.isProfilingEnabled()) { return Enabled.create(); } else { return Disabled.INSTANCE; } }
/** * Call to create a new instance of a branch profile. * * @since 0.10 */ public static BranchProfile create() { if (Profile.isProfilingEnabled()) { return Enabled.create0(); } else { return Disabled.INSTANCE; } }
/** * Returns a value profile that profiles the exact value of a <code>double</code> using * {@link Double#doubleToRawLongBits(double)}. * * @see IntValueProfile * @since 0.10 */ public static DoubleValueProfile createRawIdentityProfile() { if (Profile.isProfilingEnabled()) { return Enabled.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a {@link PrimitiveValueProfile} that speculates on the primitive equality or object * identity of a value. * * @since 0.10 */ public static PrimitiveValueProfile createEqualityProfile() { if (Profile.isProfilingEnabled()) { return Enabled.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a value profile that profiles the exact value of a <code>byte</code>. * * @see ByteValueProfile * @since 0.10 */ public static ByteValueProfile createIdentityProfile() { if (Profile.isProfilingEnabled()) { return Enabled.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a {@link PrimitiveValueProfile} that speculates on the primitive equality or object * identity of a value. * * @since 0.10 */ public static PrimitiveValueProfile createEqualityProfile() { if (Profile.isProfilingEnabled()) { return Enabled.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a value profile that profiles the exact value of an <code>long</code>. * * @see LongValueProfile * @since 0.10 */ public static LongValueProfile createIdentityProfile() { if (Profile.isProfilingEnabled()) { return Enabled.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a value profile that profiles the exact value of an <code>int</code>. * * @see IntValueProfile * @since 0.10 */ public static IntValueProfile createIdentityProfile() { if (Profile.isProfilingEnabled()) { return Enabled.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a value profile that profiles the exact value of an <code>int</code>. * * @see IntValueProfile * @since 0.10 */ public static IntValueProfile createIdentityProfile() { if (Profile.isProfilingEnabled()) { return Enabled.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a value profile that profiles the exact value of a <code>byte</code>. * * @see ByteValueProfile * @since 0.10 */ public static ByteValueProfile createIdentityProfile() { if (Profile.isProfilingEnabled()) { return Enabled.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a value profile that profiles the exact value of a <code>float</code> using * {@link Float#floatToRawIntBits(float)}. * * @see IntValueProfile * @since 0.10 */ public static FloatValueProfile createRawIdentityProfile() { if (Profile.isProfilingEnabled()) { return Enabled.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a value profile that profiles the exact value of a <code>float</code> using * {@link Float#floatToRawIntBits(float)}. * * @see IntValueProfile * @since 0.10 */ public static FloatValueProfile createRawIdentityProfile() { if (Profile.isProfilingEnabled()) { return Enabled.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a value profile that profiles the exact value of a <code>double</code> using * {@link Double#doubleToRawLongBits(double)}. * * @see IntValueProfile * @since 0.10 */ public static DoubleValueProfile createRawIdentityProfile() { if (Profile.isProfilingEnabled()) { return Enabled.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a {@link LoopConditionProfile} that speculates on loop conditions to be never * <code>true</code>. It also captures loop probabilities for the compiler. Loop condition * profiles are intended to be used for loop conditions. * * @see LoopConditionProfile * @since 0.10 */ public static LoopConditionProfile createCountingProfile() { if (Profile.isProfilingEnabled()) { return Enabled.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a {@link LoopConditionProfile} that speculates on loop conditions to be never * <code>true</code>. It also captures loop probabilities for the compiler. Loop condition * profiles are intended to be used for loop conditions. * * @see LoopConditionProfile * @since 0.10 */ public static LoopConditionProfile createCountingProfile() { if (Profile.isProfilingEnabled()) { return Enabled.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a {@link ConditionProfile} that speculates on conditions to be never * <code>true</code> or to be never <code>false</code>. Condition profiles are intended to be * used as part of if conditions. * * @see ConditionProfile * @see ConditionProfile#createCountingProfile() * @since 0.10 */ public static ConditionProfile createBinaryProfile() { if (Profile.isProfilingEnabled()) { return Binary.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a {@link ConditionProfile} that speculates on conditions to be never * <code>true</code> or to be never <code>false</code>. Condition profiles are intended to be * used as part of if conditions. * * @see ConditionProfile * @see ConditionProfile#createCountingProfile() * @since 0.10 */ public static ConditionProfile createBinaryProfile() { if (Profile.isProfilingEnabled()) { return Binary.create(); } else { return Disabled.INSTANCE; } }
/** * <p> * Returns a value profile that profiles the object identity of a value. A single instance can * only profile one particular instance. * </p> * * <p> * <b>Compilation notes:</b> Identity profiles require a runtime check to verify their profiled * object identity. If two identities have been seen on a single profile instance then this * profile will transition to a generic state with no overhead. * </p> * * @since 0.10 */ public static ValueProfile createIdentityProfile() { if (Profile.isProfilingEnabled()) { return Identity.create(); } else { return Disabled.INSTANCE; } }
/** * Returns a {@link ConditionProfile} that speculates on conditions to be never * <code>true</code> or to be never <code>false</code>. Additionally to a binary profile this * method returns a condition profile that also counts the number of times the condition was * true and false. This information is reported to the underlying optimization system using * {@link CompilerDirectives#injectBranchProbability(double, boolean)}. Condition profiles are * intended to be used as part of if conditions. * * @see ConditionProfile * @see #createBinaryProfile() * @since 0.10 */ public static ConditionProfile createCountingProfile() { if (Profile.isProfilingEnabled()) { return Counting.create(); } else { return Disabled.INSTANCE; } }