AMD has a big wafer supply agreement with GlobalFoundries, and has since the spinoff. It was exclusive until the seventh WSA in 2019 which allowed AMD to purchase 7nm and beyond from other suppliers (without paying penalties) which was the only reasonable resolution after GloFo cancelled their 7nm fab (which may have been the best thing to happen to AMD). But AMD increased their GloFo orders in May and December 2021 during the chip crunch to $2.1B total through 2025. If you look at the first WSA amendment from March 2011 it includes AMD agreeing to pay an additional $430M if they get some (redacted) node in production in time.
Anyway, whatever woes GloFo is facing you can’t blame them on AMD. They had an exclusivity deal for a decade which only got broken when it was no longer tenable and AMD still buys a ton of their wafers. I suppose AMD may have bought more wafers if their products didn’t suck for most of that time but it had nothing to do with shifting production to TSMC which only happened after GloFo gave up.