I'm sorry to hear this.
Please urgently see a vet.
Please urgently step in and syringe feed him either a fibre rich recovery feed such as oxbow critical care or mush his guinea pig pellets with warm water to make a slurry to syringe feed to him.
This is urgent. Poop output is 1-2 days behind food intake so if he isn’t pooping then he hasn’t eaten any food for many days. A piggy who isn’t eating and isn’t pooping urgently needs help.
Their system needs fibre (hay) to be constantly going through it and without their system can shut down (stasis).
You need to switch from the routine weekly weight checks and instead weigh him every morning so you can ensure you get enough syringe feed into him. He needs to be fed around the clock, every two hours as much as he will take at each sitting.
What gas medicine have you given him?
Bloat is painful so he also needs pain meds from the vet.
Please read the green links I’ve added below. They explain how to syringe feed, how important it is and how bloat needs to be dealt with
I hope he is ok
Emergency and Crisis Care as well as Bridging Care until a Vet Appointment
Not Eating, Weight Loss And The Importance Of Syringe Feeding Fibre
All About Syringe Feeding and Medicating Guinea Pigs with Videos and Pictures
Digestive Disorders: Not Eating - Diarrhea - Bloat - GI Stasis (No Gut Movement)