> Suppose $5T USD was funneled into all research over the last 10 years.
Hard to answer exactly, but we can get a decent answer. A quick quack (search)[0] shows that in 2013 the US spent $435bn in research (We'll round to an even $500bn) funding. So to answer your question:
> How much of that would virology/epidemiology have gotten, and would it have been enough?
Exactly as much as they already got and in exactly the same way it has.
But this answers your question too specifically because it is just all funding. Personally I'm in the view that if we're not in an active war we should be focusing more money into R&D. Science has a ROI of 1 year - a few hundred years, with 20 years probably being around the mean. A 10-30 year investment is not something I want my industry to focus around (or something I can expect industry to even spend money on because their incentives are not aligned for that). But it IS something I want my country to be focused on, because even 50 years for a country is not that long. I also want that knowledge in the public domain so businesses can form around these new things. Essentially the gov raises the tide and all boats benefit, even the people that are making new boats. I want my government to be funding basic scientific research because often there is no immediate benefit from this but the long term benefits are huge. Institutions like NASA and CERN don't spin off technologies because there is something unique about them, they spin off technologies because they are pushing the edges of technological capabilities and have to invent new components along the way, things they didn't know they needed. This isn't something I can expect a company smaller than FAANG to invest in.
[0] https://www.nsf.gov/statistics/2015/nsf15330/nsf15330.pdf
[1] Further breakdown: https://www.nsf.gov/statistics/2017/nsf17316/