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

AArch64: Fix build failure after JDK-8211029

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P4 P4
    • 12
    • 12
    • hotspot
    • aarch64
    • linux

      Commit "8211029: Have a common set of enabled warnings for all native libraries" breaks AArch64 build.

      Some code style issues in AArch64 should be fixed after "-Werror=c++11-compat" and "-Werror=switch" turned on.


      part of the failure log:

      -----
      For target hotspot_variant-server_libjvm_objs_c1_LIRGenerator_aarch64.o:
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/c1_LIRGenerator_aarch64.cpp: In member function 'virtual void LIRGenerator::do_ArithmeticOp(ArithmeticOp*)':
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/c1_LIRGenerator_aarch64.cpp:582:10: error: enumeration value 'objectTag' not handled in switch [-Werror=switch]
      switch (tag) {
      ^
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/c1_LIRGenerator_aarch64.cpp:582:10: error: enumeration value 'addressTag' not handled in switch [-Werror=switch]
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/c1_LIRGenerator_aarch64.cpp:582:10: error: enumeration value 'metaDataTag' not handled in switch [-Werror=switch]
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/c1_LIRGenerator_aarch64.cpp:582:10: error: enumeration value 'number_of_legal_tags' not handled in switch [-Werror=switch]
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/c1_LIRGenerator_aarch64.cpp:582:10: error: enumeration value 'voidTag' not handled in switch [-Werror=switch]
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/c1_LIRGenerator_aarch64.cpp:582:10: error: enumeration value 'illegalTag' not handled in switch [-Werror=switch]
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/c1_LIRGenerator_aarch64.cpp:582:10: error: enumeration value 'number_of_tags' not handled in switch [-Werror=switch]
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/c1_LIRGenerator_aarch64.cpp: In member function 'void LIRGenerator::do_MathIntrinsic(Intrinsic*)':
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/c1_LIRGenerator_aarch64.cpp:786:14: error: enumeration value '_none' not handled in switch [-Werror=switch]
      ... (rest of output omitted)

      For target hotspot_variant-server_libjvm_objs_macroAssembler_aarch64.o:
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/macroAssembler_aarch64.cpp:1508:38: error: C++11 requires a space between string literal and macro [-Werror=c++11-compat]
      snprintf(buffer, sizeof(buffer), "0x%"PRIX64, imm64);
      ^
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/macroAssembler_aarch64.cpp:1571:38: error: C++11 requires a space between string literal and macro [-Werror=c++11-compat]
      snprintf(buffer, sizeof(buffer), "0x%"PRIX64, imm64);
      ^
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/macroAssembler_aarch64.cpp:1684:40: error: C++11 requires a space between string literal and macro [-Werror=c++11-compat]
      snprintf(buffer, sizeof(buffer), "0x%"PRIX32, imm32);
      ^
      cc1plus: all warnings being treated as errors

      For target hotspot_variant-server_libjvm_objs_templateTable_aarch64.o:
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/templateTable_aarch64.cpp: In static member function 'static void TemplateTable::resolve_cache_and_index(int, Register, Register, size_t)':
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/templateTable_aarch64.cpp:2329:10: error: enumeration value '_illegal' not handled in switch [-Werror=switch]
      switch (code) {
      ^
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/templateTable_aarch64.cpp:2329:10: error: enumeration value '_nop' not handled in switch [-Werror=switch]
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/templateTable_aarch64.cpp:2329:10: error: enumeration value '_aconst_null' not handled in switch [-Werror=switch]
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/templateTable_aarch64.cpp:2329:10: error: enumeration value '_iconst_m1' not handled in switch [-Werror=switch]
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/templateTable_aarch64.cpp:2329:10: error: enumeration value '_iconst_0' not handled in switch [-Werror=switch]
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/templateTable_aarch64.cpp:2329:10: error: enumeration value '_iconst_1' not handled in switch [-Werror=switch]
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/templateTable_aarch64.cpp:2329:10: error: enumeration value '_iconst_2' not handled in switch [-Werror=switch]
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/templateTable_aarch64.cpp:2329:10: error: enumeration value '_iconst_3' not handled in switch [-Werror=switch]
      /home/penli01/jdk_src/src/hotspot/cpu/aarch64/templateTable_aarch64.cpp:2329:10: error: enumeration value '_iconst_4' not handled in switch [-Werror=switch]
      ... (rest of output omitted)

            aph Andrew Haley
            njian Ningsheng Jian (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: