Sun Microsystems has announced that it will lay off 15 percent to 18 percent of its workforce, as the company seeks to save $700 million to $800 million a year in costs. Sun also said that its top software executive is leaving the company.

The cost cutting will see between 5,000 and 6,000 staff leave the company. Sun is also reorganising its software division, a move it said stands as "a recognition of the comprehensive role software plays in the company's growth strategy."

Meanwhile, Rich Green, the company's executive vice president of software, has decided to leave the company. Sun said Green "has been an instrumental force in evolving Sun's Software strategy and successful business execution across its diverse portfolio."

Sun's software division changes include a new group, Application Platform Software, which includes Sun's MySQL database and infrastructure technology like the GlassFish application server.

The Cloud Computing & Developer Platforms group will focus on web-based services as well as Sun's NetBeans development platform. Also, Sun's Solaris, virtualisation and system management software teams will be moved into the company's systems group.

All changes are effective immediately, Sun said.

Sun said the economy sparked the changes.

"Today, we have taken decisive actions to align Sun's business with global economic realities and accelerate our delivery of key open source platform innovations," CEO Jonathan Schwartz said in a statement.

At the end of October, Sun blamed the downturn in the financial sector for a $1.68 billion quarterly loss. The collapse of Wall Street over the last two months eliminated several key Sun customers.

Sun has also been struggling overall for some time due to slumping sales of its high-end servers.

Angry Sun shareholders have been pressing company officials to improve its performance. Sun's share price has fallen from about $17 at the beginning of this year to roughly $4 at the start of trading Friday.

"The fact that the stock has been diving and diving and diving and is never pulling out of this dive, you start to wonder - how long can you keep diving before you lose all your stockholders?" one shareholder said during the company's recent shareholder meeting. "How long can you be in freefall and still survive?"

Schwartz told the crowd that Sun is trying to reinvent itself by developing new server systems and attracting new customers with its open-source software portfolio. But that strategy has not borne fruit quickly.