Underlying is often used when speaking of financial derivatives. The derivative financial instrument (say a bond pool of mortgages or a call option on a stock) derives some of its value from the underlying instrument (the mortgages or the stock).
The closest meaning is the OP's second definition.
used to describe something on which something else is based
Here's a description of a bond pool, also called a Mortgage-Backed Security (MBS):
GNMAs are mortgage-backed securities that are issued by the Government National Mortgage Association (a.k.a. Ginnie Mae) and guaranteed by the federal government. For those not familiar with mortgage-backed securities, Vanguard describes them this way:
MBS are an investment in a pool of mortgage loans, which are the underlying asset and provide cash flow for the securities. MBS are commonly referred to as “pass-through” securities, as the principal and interest of the underlying mortgage loans “passes through” to the investor. All bondholders receive a monthly pro-rata distribution of principal and interest over the life of the security.
Source: How Do GNMA Bonds Work?
An important point that Michael Lewis was making in The Big Short is that the bond pools should have derived their credit quality from the underlying mortgages. The rating agencies, Moody's and S&P, should have lowered the ratings of the bond pools to reflect the lower ratings of the underlying mortgages.
The falling of the Jenga block tower in the movie was a vivid way to describe the consequences of failing to have the derived instruments correctly reflect the value and quality of the underlying instruments.