Are gtests executed on the primordial thread?

David Holmes david.holmes at
Thu Dec 15 08:48:08 UTC 2016

Hi Thomas,

On 15/12/2016 6:27 PM, Thomas Stüfe wrote:
> Hi all,
> It seems to me the gtestLauncher executes its tests on the primordial
> thread. Is that correct?

I think so, but I'm unclear how gtest hangs together.

> If yes, would it not be better to run the test on a separate thread,

That would then require some platform specific threading code ... unless 
we assume pthreads?

> similar to how the standard launcher creates the VM? That way the tests
> would be closer to what the actual usage scenario of the VM.
> Depending on the platform, there are quite a bit of differences between
> running on the primordial thread or on a secondary pthread. Currently
> invoking the VM on AIX on the primordial thread does not work at all - we
> excluded that scenario for a number of reasons when doing the initial port,
> and even though we could rethink this decision I would prefer not having to
> deal with that right now just to be able to run the gtests.

The only difference I'm aware of is the initial stack setup and the 
stack guard configuration. Are there others?


> Thanks, Thomas

More information about the hotspot-runtime-dev mailing list