Absolutely, but that's not something you fix at company level.
Am I the only one old enough to remember when we still had homemade products competing with chinese cheap products on the shelves? Consumers picked the Chinese version over and over, until the local plant shut down (or was delocalized in China…).
You could have had exactly the same speech about CEOs at the time: if your market is western consumers (at the time, China was not yet rich enough to have a significant local demand), who are you going to sell to when everyone has lost their job because of delocalization?
Answer is indeed: that's not my problem to solve. It's a systematic issue, it should be addressed through regulation.
CEO's job is not to address that, it's too maximize values for shareholders. If laying off everyone and use AI does that, then executing is just them doing their job right. If regulation bans or adds a high enough penalty on such a move, they won't do it.