Warren Buffett, the billionaire investor whose fortune swelled this year with a surge in Berkshire Hathaway Inc.’s share price, contributed about $2 billion in stock to the foundation created by Microsoft Corp. co-founder Bill Gates.

Buffett, Berkshire’s chairman and chief executive officer, donated about 17.5 million of his company’s Class B shares in his annual gift to the Bill and Melinda Gates Foundation, the Omaha, Nebraska-based firm said today in a statement. The stock has climbed 29 percent this year to $115.46 at 11:36 a.m. in New York.

Buffett is a trustee of the foundation and the world’s third-richest man with a net worth of about $61 billion, according to the Bloomberg Billionaires Index, a daily ranking of the wealthiest people. He has campaigned to promote charitable giving among the wealthy through the Giving Pledge initiative.

“The truth is I have never given a penny away that had any utility to me,” Buffett, 82, said last month at the Forbes 400 Summit on Philanthropy. For millions of people who aren’t rich, donating money “really means they’re giving up a movie, or a dinner out, or if it’s a larger sum, maybe a trip to Disneyland.”

Buffett also donated about 1.7 million of his company’s Class B shares to the Susan Thompson Buffett Foundation and about 1.2 million shares each to the Howard G. Buffett Foundation, the NoVo Foundation and the Sherwood Foundation, according to the statement.