< prev index next >

src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ResolvedJavaMethod.java

Print this page

444      *
445      * @return {@code this.getCodeSize() != 0}
446      */
447     default boolean hasBytecodes() {
448         return getCodeSize() != 0;
449     }
450 
451     /**
452      * Checks whether the method has a receiver parameter - i.e., whether it is not static.
453      *
454      * @return whether the method has a receiver parameter
455      */
456     default boolean hasReceiver() {
457         return !isStatic();
458     }
459 
460     /**
461      * Determines if this method is {@link java.lang.Object#Object()}.
462      */
463     default boolean isJavaLangObjectInit() {
464         return getDeclaringClass().isJavaLangObject() && getName().equals("<init>");
465     }
466 
467     /**
468      * Gets a speculation log that can be used when compiling this method to make new speculations
469      * and query previously failed speculations. The implementation may return a new
470      * {@link SpeculationLog} object each time this method is called so its the caller's
471      * responsibility to ensure the same speculation log is used throughout a compilation.
472      */
473     SpeculationLog getSpeculationLog();
474 }

444      *
445      * @return {@code this.getCodeSize() != 0}
446      */
447     default boolean hasBytecodes() {
448         return getCodeSize() != 0;
449     }
450 
451     /**
452      * Checks whether the method has a receiver parameter - i.e., whether it is not static.
453      *
454      * @return whether the method has a receiver parameter
455      */
456     default boolean hasReceiver() {
457         return !isStatic();
458     }
459 
460     /**
461      * Determines if this method is {@link java.lang.Object#Object()}.
462      */
463     default boolean isJavaLangObjectInit() {
464         return getDeclaringClass().isJavaLangObject() && (getName().equals("<init>") || getName().equals("<vnew>"));
465     }
466 
467     /**
468      * Gets a speculation log that can be used when compiling this method to make new speculations
469      * and query previously failed speculations. The implementation may return a new
470      * {@link SpeculationLog} object each time this method is called so its the caller's
471      * responsibility to ensure the same speculation log is used throughout a compilation.
472      */
473     SpeculationLog getSpeculationLog();
474 }
< prev index next >