They got it right initially, making Solaris with gate-array and that was a big success. Small company got RISC chip out fast and it beat what was out-there.
Then they went all in on CMOS-Bipolar chip, that was massively late, massively expensive. The completely lost the plot and were not competitive in the early 90s. Thankfully they had the software buy in from costumers, and did some good stuff otherwise (they also did the disastrous Solaris transition) but they overcame all that.
Then they did a bit better with UltraSPARC in 1995, they were still not top of the line, getting easily crushed by Alpha and others. But it was 64 bit and that helped them long term. Nowhere near 'excellent' for the time period. More like, good enough. Then they rolled on from there, but were never anywhere close to Alpha and others until around 2000.
They made all the mistakes you can make in the 90s, going heavy into Gallium Arsenide that was a disaster. Then they went heavy on VLIW technology in another disaster.
Then they completely lost the plot in the early 2000s, and eventually pretty much gave up completely and switched to marketing T1 chips and 'threw-put computing' because they couldn't produce competitive chips on single thread performance.
In fact they did switch from Texas Instruments to TSMC in that time period. You can read about that in 'Life Under the Sun: My 20-Year Journey at Sun Microsystems'. Don't take everything in that book at face value, its very much putting a positive spin on things, but it tells some of those stories.