I guess I should start with welcome . So hi and how are you. Assuming you got your pup from a good and concerned (interested breeder) it may have been an idea to give them a call and let them know what is going on . They may have been able to tell you that it is a bit of a nervous gut from the upheaval and changes in food, water , schedule , adjusting to no litter mates , no mum-dog . 8 weeks is still very young .
The dog may have had a recent vaccination prior to joining your family. This is a physiological stressor and some pups may be sleepy or have a bit of rise in temperature.
Digestion is slowed . Gas forms when digestion is slowed .
Be careful with x rays . They are not benign and should be used only when the situation merits it . I think a pup this age could have had a physical palpation of the stomach , and that x rays were over kill. Be careful that you don't have a vet who oversells products or procedures , takes advantage of your newbie status in dog ownership.
A little slippery elm powder , marshmallow root powder , will sooth the stomach.
wondering what the "pills" are ?