JDK-8200299 : Non-PCH build for aarch64 fails
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 11
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • CPU: aarch64
  • Submitted: 2018-03-27
  • Updated: 2019-11-13
  • Resolved: 2018-03-27
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 11
11 b10Fixed
Related Reports
Relates :  
Relates :  
Description
Current jdk/hs fails the --disable-precompiled-headers build like this:

* For target hotspot_variant-server_libjvm_objs_ad_aarch64.o:
In file included from ad_aarch64.cpp:30:0:
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad: In static member function 'static uint HandlerImpl::size_exception_handler()':
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad:1028:12: error: incomplete type 'MacroAssembler' used in nested name specifier
     return MacroAssembler::far_branch_size();
            ^~~~~~~~~~~~~~
* For target hotspot_variant-server_libjvm_objs_ad_aarch64_clone.o:
In file included from ad_aarch64_clone.cpp:29:0:
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad: In static member function 'static uint HandlerImpl::size_exception_handler()':
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad:1028:12: error: incomplete type 'MacroAssembler' used in nested name specifier
     return MacroAssembler::far_branch_size();
            ^~~~~~~~~~~~~~
* For target hotspot_variant-server_libjvm_objs_ad_aarch64_expand.o:
In file included from ad_aarch64_expand.cpp:29:0:
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad: In static member function 'static uint HandlerImpl::size_exception_handler()':
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad:1028:12: error: incomplete type 'MacroAssembler' used in nested name specifier
     return MacroAssembler::far_branch_size();
            ^~~~~~~~~~~~~~
* For target hotspot_variant-server_libjvm_objs_ad_aarch64_format.o:
In file included from ad_aarch64_format.cpp:29:0:
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad: In static member function 'static uint HandlerImpl::size_exception_handler()':
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad:1028:12: error: incomplete type 'MacroAssembler' used in nested name specifier
     return MacroAssembler::far_branch_size();
            ^~~~~~~~~~~~~~
* For target hotspot_variant-server_libjvm_objs_ad_aarch64_gen.o:
In file included from ad_aarch64_gen.cpp:29:0:
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad: In static member function 'static uint HandlerImpl::size_exception_handler()':
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad:1028:12: error: incomplete type 'MacroAssembler' used in nested name specifier
     return MacroAssembler::far_branch_size();
            ^~~~~~~~~~~~~~
* For target hotspot_variant-server_libjvm_objs_ad_aarch64_misc.o:
In file included from ad_aarch64_misc.cpp:29:0:
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad: In static member function 'static uint HandlerImpl::size_exception_handler()':
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad:1028:12: error: incomplete type 'MacroAssembler' used in nested name specifier
     return MacroAssembler::far_branch_size();
            ^~~~~~~~~~~~~~
* For target hotspot_variant-server_libjvm_objs_ad_aarch64_peephole.o:
In file included from ad_aarch64_peephole.cpp:29:0:
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad: In static member function 'static uint HandlerImpl::size_exception_handler()':
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad:1028:12: error: incomplete type 'MacroAssembler' used in nested name specifier
     return MacroAssembler::far_branch_size();
            ^~~~~~~~~~~~~~
* For target hotspot_variant-server_libjvm_objs_ad_aarch64_pipeline.o:
In file included from ad_aarch64_pipeline.cpp:29:0:
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad: In static member function 'static uint HandlerImpl::size_exception_handler()':
/home/shade/jdk-hs/src/hotspot/cpu/aarch64/aarch64.ad:1028:12: error: incomplete type 'MacroAssembler' used in nested name specifier
     return MacroAssembler::far_branch_size();
            ^~~~~~~~~~~~~~

Relates to JDK-8199809, because that seems to be the first changeset where it starts to fail with this kind of error. Although, there are multiple other non-PCH issues even before that change.
Comments
After fixing aarch64.ad, another failure pops up: * For target hotspot_variant-server_libjvm_objs_privilegedStack.o: In file included from /home/shade/jdk-hs/src/hotspot/share/utilities/events.hpp:30:0, from /home/shade/jdk-hs/src/hotspot/share/gc/shared/collectedHeap.hpp:35, from /home/shade/jdk-hs/src/hotspot/share/oops/oop.inline.hpp:29, from /home/shade/jdk-hs/src/hotspot/share/prims/privilegedStack.cpp:29: /home/shade/jdk-hs/src/hotspot/share/runtime/thread.hpp:1163:26: error: inline function ���JavaThreadState JavaThread::thread_state() const��� used but never defined [-Werror] inline JavaThreadState thread_state() const; ^~~~~~~~~~~~ cc1plus: all warnings being treated as errors Which seems to be the overlook from including thread.hpp, but not thread.inline.hpp in events.hpp
27-03-2018