The purpose and function of mortal incarnate life is not reducible to one thing - mortal incarnate life is not reducible to salvation unless salvation is given a dual meaning, in which case the duality of purpose is being covertly (and often insensibly) smuggled-in.
All Men live and die - that experience is common to all Men and to Jesus Christ - and that is the 'mechanism' of salvation. All that humans need to do is accept Christ's offer and gift of salvation (although that acceptance may not be as easy as it sounds given the corruptions of a long life in this world; and certainly acceptance of Christ's work cannot be assumed to be universal.)
But most Men are incarnated and die either in the womb or at or soon after birth; and more die while innocent babes or young children. These all experience the essential experience which is necessary for salvation.
The basic experience of mortal life is that our pre-mortal eternal souls are clothed in a body, then die and become separated from that body - but not only the 'physical' body. Our souls also experience dwelling within a personality, a specific set of dispositions, abilities, motivations etc. You could summarize this by saying our souls dwell inside a mind, and the characteristics of that mind - and the mind is not the soul.
This 'personality' or mind is also part of the body (that is it depends on the body - especially the brain) and the soul also separates from the mind at death.
So, during mortal life the soul and personality/ body are in a state of necessary disharmony (this is what some Christians call original sin) but after resurrection the soul is perfectly in harmony with the body/ personality.
Spiritual progression is linear and sequential, like Time. The primary aim of mortal incarnate life is salvation - which is first the experience of the soul dwelling in a state of disharmony with a personality/ body and then dying to be resurrected to the condition of a soul dwelling in harmony with personality/ body (unless the soul refuses the resurrection to harmony - unless the soul refuses to let go of the conflicted aspects of the body/ personality).
The aim of resurrection into harmony can only be achieved via the experience of mortal incarnate life and death, and via the work of Jesus Christ who underwent these experiences.
All this is salvation - but theosis refers to the degree of progress towards divine-nature achieved during mortal incarnate life; and this depends upon length of life and circumstances and opportunities of life - as well as upon choices, will, and other personal factors.
A long life (i.e. to maturity, to include more primary experiences such as marriage and children, creative work, friendships, self-sacrifice etc) offers more possibilities of theosis - of a higher degree of advancement, and more possibilities of corruption.
The value of a long life may be remedial in some instances (a chance for those who most need it; pre-mortal spirits who are significantly deficient), or to enable a more advanced level of spirituality (a chance for those best able to make the most of opportunities). Or mixtures.
Most of religious discourse which purports to be about salvation is really about theosis - it is about that small minority of humans who have lived a long life.
We should never forget that God's plan will very probably have been focused primarily on the majority of Men who never made it out of the womb, or early childhood. The plan was mostly about them; and only secondarily about us, about you and I - part of that tiny minority of long-lived Men whose business ought to be theosis.
(Although, tragically, many of us who live in the secular West explicitly state that we fully intend to reject salvation - and actively aim to persuade others to do likewise. But, fortunately, this madness has not afflicted the mass of men in history and does not afflict the majority alive today.)