Sun Microsystems (NASDAQ:SUNW) is having one nightmare of a week.

On Monday, the computer maker issued an earnings warning while tacking on a $1.05 billion charge to last quarter. Yesterday, Merrill Lynch (NYSE:MER) analyst Steve Milunovich sent a hostile open letter to the company's board stating that "Sun faces a crisis." And now this.

Friday morning, Hewlett Packard (NYSE:HPQ) announced that it would pay Sun customers $25,000 to switch to HP computers running Linux OS freeware.

Sun is getting picked apart by HP and IBM (NYSE:IBM) on the high end and Dell Computer (NASDAQ:DELL) on the low end. Sun's proprietary hardware is struggling to compete with cheaper systems running Linux or Microsoft's (NASDAQ:MSFT) Windows on Intel (NASDAQ:INTC) chips.

In yesterday's letter, Milunovich suggested sweeping reforms were necessary to keep Sun from becoming "irrelevant." Among other things, Milunovich recommended cutting up to 7,000 employees, or 19% of Sun's workforce. He also added to the speculation that Sun -- which has $5.6 billion in cash -- might be an acquisition target. The potential acquirers? "IBM, HP, possibly Fujitsu."

Suddenly, Sun, once known as the dot in, risks becoming little more than a dot in history. CEO Scott McNealy, who was a big factor in the company's success, may turn out to be as big a factor in its failure. Clearly, his reluctance to cut costs in a timely manner and focus on advantages has left Sun in a poor competitive position.

And just as clearly, Sun's warning early this week is evidence of that weakness, as was its chief scientist's departure and the decision to start cutting jobs. Now, HP is looking to capitalize on Sun's lack of focus by cutting prices further in what is already a buyers market.

Sun was already having a bad week. Hewlett Packard just provided its fitting end.

Jeff Hwang can be reached at