[8] Shenandoah: Fix build failure with +JFR -PCH
Roman Kennke
rkennke at redhat.com
Tue Jun 2 20:29:59 UTC 2020
JFC :-) Looks good, thank you!
Roman
Aleksey Shipilev <shade at redhat.com> schrieb am Di., 2. Juni 2020, 13:05:
> Hi,
>
> Current sh/jdk8 build fails if configured --enable-jfr and
> --disable-precompiled-headers like this:
>
> In file included from
>
> /home/shade/trunks/shenandoah-jdk8/hotspot/src/share/vm/jfr/instrumentation/jfrJvmtiAgent.cpp:29:0:
> /home/shade/trunks/shenandoah-jdk8/hotspot/src/share/vm/jfr/jni/jfrUpcalls.hpp:57:10:
> error:
> ‘instanceKlassHandle’ does not name a type; did you mean ‘InstanceKlass’?
> static instanceKlassHandle load_event_handler_proxy_class(TRAPS);
> ^~~~~~~~~~~~~~~~~~~
> InstanceKlass
>
> I notice we already have this upstream difference in os.hpp that unties
> the header circularity:
>
> --- old/src/share/vm/runtime/os.hpp 2020-06-02 01:08:37.190316031 +0200
> +++ new/src/share/vm/runtime/os.hpp 2020-06-02 01:08:37.110316134 +0200
> @@ -28,7 +28,6 @@
> #include "jvmtifiles/jvmti.h"
> #include "runtime/atomic.hpp"
> #include "runtime/extendedPC.hpp"
> -#include "runtime/handles.hpp"
> #include "utilities/top.hpp"
> #ifdef TARGET_OS_FAMILY_linux
> # include "jvm_linux.h"
> @@ -54,6 +53,7 @@
> #endif
>
> class AgentLibrary;
> +class methodHandle;
>
> I tried to revert that block and solve it by rearranging Shenandoah
> includes a bit, but to no avail.
> So, this is my plan B that seems to solve the build failure:
>
> diff -r 4439a43801a4 src/share/vm/runtime/os.hpp
> --- a/src/share/vm/runtime/os.hpp Mon Jun 01 19:14:49 2020 +0200
> +++ b/src/share/vm/runtime/os.hpp Tue Jun 02 11:17:51 2020 +0200
> @@ -52,10 +52,11 @@
> # endif
> #endif
>
> class AgentLibrary;
> class methodHandle;
> +class instanceKlassHandle;
>
> // os defines the interface to operating system; this includes traditional
> // OS services (time, I/O) as well as other functionality with system-
> // dependent code.
>
> Testing: Linux x86_64 builds with {+JFR, -JFR} x {+PCH, -PCH} x {release,
> fastdebug, slowdebug}
>
> --
> Thanks,
> -Aleksey
>
>
More information about the shenandoah-dev
mailing list