Sun had few paths forward, with Linux + commodity hardware, what were they going to do, keep selling the OS and support contract at a price fewer and fewer were willing to pay? Sun had a suite of IDE and compilers that at one time sold for thousands of dollars per seat, the compiler was optimized for the architecture, but gdb was free and can get you code that runs just as well, unless you're under a benchmark. They were also under pressure from the OpenSource dev tools that were getting richer for GNU + Linux. Now that Solaris is practically dead, and RHEL is a subsidiary of IBM, given the dev and support state of CentOS and RockyLinux, I wonder if the community ever regret the loss of what could have flourished as another branch of the *nix ecosystem.
I mean, I regret it to this day.
Solaris had (and illumos has) truly unmatched tooling around a number of things.