Sam Palmisano earned a total compensation package of $31.8 million in his last year as chairman and chief executive officer at IBM (NYSE: IBM), the world’s largest technology company reported in an SEC filing.

Bloomberg News reported the details.

Palmisano’s package of salary, bonus, stock and stock options was slightly higher than the $31.7 million he earned in 2010, Bloomberg noted.

Palmisano stepped away from his CEO role as of Dec. 31.

His replacement, Virginia Rometty, earned $8.34 million as head of sales and marketing. That total was up from $6.4 million the previous year, Bloomberg said.

In IBM’s annual report published over the weekend, Rometty cited “disciplined execution” as a key reason behind IBM’s success. She also noted that the company is on target to meet financial goals set through 2015. (Read details here.)

Palmisano looked back on his role in IBM’s changes, which he has overseen since becoming chairman, in that report.

“As we look back on our strong performance in 2011 — the culmination of an impressive decade — Ginni and I thought it would be appropriate for me to share a perspective on this most recent phase of IBM’s 100-year journey, and to offer some thoughts on what it has taught us,” he wrote.

“I recently took a look at my notes from my first meeting with IBM’s senior leadership after becoming chairman in January 2003. I was surprised to see how little I had written down. At the top were just four questions:

“Why would someone invest in us?

“Why would customers buy from us?

“Why would society allow us to operate?

“Why would someone work here?

“Our history teaches us that IBM became one of the world’s great companies by continually creating value for all of these stakeholders. Certainly, that was the IBM I joined 38 years ago. And as IBM’s incoming chairman nine years ago, I couldn’t imagine an agenda that wasn’t built on that multidimensional goal.”

Read his full letter here.

IBM recently laid off well over 1,000 workers in North America as part of what it calls a “rebalancing.”

The company employs some 10,000 people across North Carolina.

Get the latest news alerts: Follow WRAL Tech Wire at Twitter.