G1NUMA is created at initialization list of G1CollectedHeap and then sets region size and page size later at G1CollectedHeap::initialize(). The reason of this order is G1Allocator needs G1NUMA::num_active_nodes() and G1NUMA needs region / page size for further work so sets these values when calculated at initialize().
However if delay creating G1Allocator after creating G1NUMA, we can simply.
This approach is valid but for the following enhancement of NUMA which touches HeapRegionManager may be affected. i.e. G1NUMA should be created earlier. If HeapRegionManager also can be initialized after G1NUMA, initialization of G1NUMA will be simpler.
Investigate and change it if possible.
This discussion was brought up during JDK-8220310 review but couldn't accepted because of potential HeapRegionManager initialization order issue.