I’ve noticed the same thing - Dicks and Walmart locally are usually out of 9mm, .45 & 357 mag but nearly always have .40 S&W.
I bought 3, 100 round value packs of Winchester 9mm Luger 115 GR. FMJ at Walmart today in Brewer, ME and could have bought 7 more. But two days ago at Walmart in Bangor, ME, the only pistol ammo they had was two 50 round boxes of Federal 40 S&W 180 GR FMJ FN, which I bought, and one box of 44 Rem Mag. Bangor had 6 or 7 boxes of Federal 223 in 100 round value packs two days ago, but Brewer had none today. I believe you need to go regular and buy it when it’s there.