Nuclear fusion begins earlier and proceeds more rapidly in stars with larger mass. Their nuclear fuel is used at an accelerated rate compared with smaller stars. Large stars, of course, have larger amounts of nuclear fuel, yet because they must burn at vastly increased rates their lifetimes are much shorter than lower mass stars, which live much longer. For the larger stars living at 5-10 million years or even 100 million years may not seem like a short span of time, yet it is when compared to 5-10 billion years or more. The large stars in that sense have a major part to play in what happens in the universe. If they are formed early they can significantly influence the chemistry of the long-lived stars that come later.
When stars 3-30 times larger than our sun they use up most of the hydrogen in their core, then some hydrogen fusion starts to occur in the outer reaches or the star as the helium in the inner regions, under the continuing crunch of gravity further collapses and the internal helium is gradually converted to carbon and oxygen, and subsequently into heavier elements such as iron. Once iron begins to form this signals the beginning of the end as the energy derived from continuing nuclear reactions can no longer keep pace with gravitational collapse. Many such stars will blow up in a supernova distributing a virtual periodic table of chemical elements across the universe. Stars with run-away cores end in massive explosions leaving behind either a neutron star or or a black hole while also creating the heavier elements. Massive amounts of the new elements become associated with slower forming, longer-lived stars and later find their way into the planets which become associated with the longer-lived stars.
Ultimately the stuff of planet formation in the long-lived stars and subsequently in the development of life may be formed during the destructive collapse of the more massive short-lived stores. As Carl Sagan said on more than one occasion, “we are the stuff of stars.”