The first billion-dollar company was formed in 1901, and over the following 117 years, the industries that created the most value in the stock market transitioned between steel, car manufacturing, industrial products, and technology.

That brings us to 2018 when tech giant Apple became the first company in the world to amass a $1 trillion market capitalization. In the years since, Microsoft, Amazon, and Google parent Alphabet have joined Apple with $1 trillion valuations of their own.

If history is any guide, we might be more than a century away from the world's first quadrillion-dollar company! Plus, it's almost impossible to know what undiscovered industries could drive that value creation.

For now, let's focus on two powerful semiconductor companies that could join the exclusive $1 trillion club -- and if they get there, they could deliver monster gains for investors who buy them today.

1. Nvidia continues to drive artificial intelligence forward

Nvidia (NVDA 4.29%) is one of the best-performing stocks in 2023, with a year-to-date gain of 88%. And it's only April. The company is best known for producing some of the world's most advanced graphics chips used in gaming applications and data centers, but it's quickly gaining recognition as the leader of the artificial intelligence (AI) industry as well.

Nvidia has always been a pioneer of AI technology. In fact, in 2016, it delivered one of the world's first AI supercomputers to OpenAI, the developer of the ChatGPT online chatbot. Today, OpenAI continues to train its large language models on thousands of Nvidia's advanced graphics chips.

Cathie Wood's Ark Investment Management thinks such generative AI models could be a $14 trillion revenue opportunity by 2030, with the potential to add $200 trillion in output to the global economy by then. At this stage, Nvidia is one of the only suppliers of the tools AI developers need to unlock that value.

Nvidia CEO Jensen Huang believes computing hardware is physically limited in its ability to continuously shrink in size while delivering more performance. But thanks to AI, software can extract 1,000 times more performance from existing hardware. Now, Nvidia will give all businesses access to the infrastructure necessary to develop AI to suit their own purposes, as it's making its DGX supercomputer available online through cloud providers like Microsoft Azure.

It's prompting investors to rethink Nvidia's long-term potential because it's certainly no longer a simple semiconductor producer. It's building the software to match, making it an end-to-end platform computing company. Its Drive platform is a great example -- it provides car manufacturers with all the hardware and software needed to implement fully autonomous self-driving capabilities in their new vehicles. According to Allied Market Research, that alone could be a $2.1 trillion opportunity by 2030.

After the incredible run in Nvidia stock this year, the company is now valued at $684 billion, well on its way to reaching the $1 trillion milestone. And given the substantial opportunities in AI alone, it's quite possible it will get there by the end of the decade.

2. Advanced Micro Devices could lead the high-performance computing industry

Advanced Micro Devices (AMD 1.65%) is a fair way behind Nvidia in terms of valuation. It's currently worth just $155 billion, so its stock will have to gain 545% for the company to achieve a $1 trillion valuation. AMD produces some of the most sought-after semiconductors globally, from processors to graphics chips, and they're used in popular consumer electronics and data centers alike.

But AMD's path to the $1 trillion club might be paved by its $49 billion acquisition of Xilinx last year. Xilinx is the global leader in adaptive technology, and AMD believes the combined companies will lead high-performance computing for decades to come. Typical computer chips are sold in a solid state, so the entire unit must be swapped out with a newer model to upgrade. Adaptive hardware, on the other hand, can be reconfigured even after the manufacturing process, and depending on the workload, its output can be adjusted in a live environment.

See, while advancements in computing hardware might be incremental rather than exponential going forward, adaptive technology can help companies access performance increases more quickly -- outside of the typical upgrade cycle. Recall what I mentioned about AI software drastically making hardware more efficient; well, adaptive hardware might offer an even greater performance boost. And that might be the key to developing more advanced models.

Since AMD has a far steeper mountain than Nvidia to climb to reach a $1 trillion valuation, let's explore what it will take to get there from a mathematical standpoint. AMD grew its revenue at a compound annual rate of 34.6% over the last five years, from $5.3 billion in 2017 to $23.6 billion in 2022. Therefore, its stock trades at a price-to-sales (P/S) ratio of 6.5.

Assuming the P/S ratio remains constant, AMD will have to achieve $152 billion in annual revenue to justify a $1 trillion market cap. If it maintains its annual revenue growth rate of 34.6% on average, it could reach $152 billion in sales within the next seven years.

But even if that growth rate slows, given AMD could share in the AI opportunity with Nvidia, there's a good chance it will eventually join Apple, Amazon, Alphabet, and Microsoft in the $1 trillion club in the longer run.