Men’s Wearhouse has gone from target to hunter in less than two weeks. Investors like the way it looks.

The retailer’s shares jumped Tuesday after it offered to buy smaller rival Jos. A. Bank Clothiers for about $1.54 billion. While investment banks have pitched the idea to Men’s Wearhouse for years, the board was spurred to make the offer after the Houston-based company was itself targeted by Jos. A. Bank last month, two people with knowledge of the matter said. The switch from target to buyer is dubbed the Pac-Man defense, after the video game character that can sometimes eat the ghosts chasing after it.

Either way, the combination of the two companies could yield benefits in cost savings and expanded sales, according to Richard Jaffe, an analyst at Stifel Financial Corp. Men’s Wearhouse has a lucrative tuxedo-rental business that could be expanded to Jos. A Bank’s 611 stores, he wrote in a note Tuesday. The combined company, with about 1,700 stores, would save on purchasing, customer service and marketing expenses.

“You now have both management teams agreeing it’s a strategically sensible deal,” said Ed Bosek, a managing member of New York-based hedge fund BeaconLight Capital LLC, which owns shares of both retailers. “You put these two companies together and you have the biggest publicly listed men’s apparel company with potentially very high margins and a good business.”

Men’s Wearhouse rose nearly 8 percent to $50.60 a share Tuesday, while Jos. A. Bank gained 11 percent to $56.29 – above the $55 a share offer – indicating investors expect the purchase price to increase.

A spokeswoman for Men’s Wearhouse declined to comment further. Jos. A. Bank, based in Hampstead, Md., said it had received the proposal and that its board would evaluate it and respond in “due course.”

Men’s Wearhouse could raise the bid to as much as $59 a share, putting the valuation in line with other recent deals in the industry, said Betty Chen, a San Francisco-based analyst for Mizuho Securities.

An offer for $59 a share would value Jos. A. Bank at about $1.32 billion, after subtracting net cash, or about 10 times the company’s earnings before interest, taxes, depreciation and amortization in the past year, according to data compiled by Bloomberg. “A deal is clearly going to happen at this point, whether Men’s Wearhouse raises its offer or if Jos. A. Bank raises its bid,” said John Kernan, a New York-based analyst at Cowen Group.

Kernan estimates the combined company could produce earnings of more than $6 a share long-term if the merger is successful. In the 12 months through August, the two companies earned $4.67 a share collectively, data compiled by Bloomberg show.

Jos. A. Bank in October offered to buy Men’s Wearhouse for about $2.3 billion. Men’s Wearhouse rejected that bid, saying it was too low and was opportunistic because it came at a moment of upheaval for the company, which in June ousted Zimmer as executive chairman over disagreements about strategy.