The node you are looking for is at gnat_ugn/elaboration_order_handling_in_gnat controlling-elaboration-in-gnat-internal-calls.