The government is to "provide for the common defence"... I believe it's not a big stretch to say that common defence includes defence against a virus, bacteria, bark beatle, and other health and safety problems.. It falls under the same authority that grants the Feds the right to have federal police or a federal army. Be they policing people or combating infectious agents.. The Centers for Disease Control is fully federal funded. They are operating under the same authority and mandate.
I think donating tax money to Planned Parenthood is far more questionable than to found a scientific agency for eliminating a particular problematic virus. I'd also note that research into the various strains of HIV has brought several life-saving advances to other areas of medical research, particularly in the areas of retroviruses and cancer.