diff -r cc231bd80c8b -r 7638bf98a312 src/hotspot/share/runtime/vm_operations.hpp --- a/src/hotspot/share/runtime/vm_operations.hpp Sat Jan 13 02:56:22 2018 +0100 +++ b/src/hotspot/share/runtime/vm_operations.hpp Tue Nov 21 09:47:55 2017 -0500 @@ -115,6 +115,7 @@ template(ICBufferFull) \ template(ScavengeMonitors) \ template(PrintMetadata) \ + template(GTestExecuteAtSafepoint) \ class VM_Operation: public CHeapObj { public: @@ -286,6 +287,17 @@ bool is_cheap_allocated() const { return true; } }; +// Base class for invoking parts of a gtest in a safepoint. +// Derived classes provide the doit method. +// Typically also need to transition the gtest thread from native to VM. +class VM_GTestExecuteAtSafepoint: public VM_Operation { + public: + VMOp_Type type() const { return VMOp_GTestExecuteAtSafepoint; } + + protected: + VM_GTestExecuteAtSafepoint() {} +}; + class VM_Deoptimize: public VM_Operation { public: VM_Deoptimize() {}