Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8322583

RISC-V: Enable fast class initialization checks

XMLWordPrintable

    • b05
    • riscv
    • linux

        I note that linux-riscv64 doesn't enable fast_class_init by default. It seems that the reason is we are lacking following code change for this platform:

        ```

        diff --git a/src/hotspot/cpu/riscv/vm_version_riscv.hpp b/src/hotspot/cpu/riscv/vm_version_riscv.hpp
        index 3c769ebfe2a..c0737996106 100644
        --- a/src/hotspot/cpu/riscv/vm_version_riscv.hpp
        +++ b/src/hotspot/cpu/riscv/vm_version_riscv.hpp
        @@ -205,6 +205,8 @@ class VM_Version : public Abstract_VM_Version {
           static void initialize();
           static void initialize_cpu_information();
         
        +  static bool supports_fast_class_init_checks() { return true; }
        +
           constexpr static bool supports_stack_watermark_barrier() { return true; }
         
           static bool supports_on_spin_wait() { return UseZihintpause; }

        ```

              gcao Gui Cao
              gcao Gui Cao
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: