What time of year is your trip?
There's definitely enough to keep you busy in Santiago de Compostela for a solid day of sightseeing. The historic area is quite large, so a second day wouldn't be wasted if you enjoy just wandering around.
You might check to see whether you can get a better connection into Vigo. It's about my least favorite city/town in Galicia (not bad, but really paled in comparison to every other place I visited), but it's not far from Santiago de Compostela.
If not (and I didn't see anything great after a quick check on Google Flights for a randomly-chosen date in May), I see that--for at least some months of the year--there are cheap non-stops into Vigo from Barcelona, Madrid, Bilbao and Lisbon. This would probably end up being a separately-ticketed flight, so it would be prudent to plan at least a one-night stopover in the transfer city so you don't need to worry about missing the connecting flight if you have a transatlantic delay. With only a day or two to play with, I'd probably choose Bilbao, since you can actually see a good bit of what it has to offer in 24 or 48 hours--which cannot be said of Madrid or Barcelona. (But again, the time of year matters.) I'd suggest two nights there since your arrival day will probably be a jetlagged fog.
Additional places to see in Galicia: A Coruna (tends to be warmer and sunnier), Pontevedra, the medium-sized town of Betanzos up near A Coruna, and the small towns of Cambados, Combarro and Tui. The latter is on the Spanish border. My guess is that Cambados and Combarro would be dead off-season.
Additional places to see in northern Portugal (these are just the places I've been--not saying they are "the best"): Barcelos, Guimaraes, Viseu. There's also the Douro Valley, especially if you like wine.
In a case like this, with limited time, I'd get Spanish and Portuguese guide books out of my library, make a list of places that sounded interesting, then make a selection based on public-transportation schedules. There's no sense in twisting yourself into knots, trying to get somewhere that takes 4 hours, when there are other charming places only an hour or two away. But do try to hit a weekly market day somewhere; those are fun.
Lisbon and Porto both will benefit from multiple days, so you don't really have that much extra time to fill.
Keep in mind that transportation across the Spanish/Portuguese border is infrequent, so figure out what your options are sooner rather than later. You may find that Sunday is a day to be avoided.