As you can see in the script opcode, the push instructions are
never evaluated. If they were, then all of these gigantic ordinals transactions would fail because they would overflow the stack. The manner in which the Ordinals transactions are spent is by using the conventional Schnorr signature directly, not any of the leaf evaluations. And also P2TR outputs
do not count any sigops so its effectively limited only by block size, i.e. it's possible to fill an entire block with a large enough Ordinal.