This commentary originally appeared on Real Money Pro at 11:30 a.m. on Feb. 17. Click here to learn about this dynamic market information service for active traders.

Decades ago, IBM (IBM) and Hewlett Packard were celebrated as titans of technology. However, as tech evolved, these names lost their appeal. Innovations from companies like Apple (AAPL) and low-cost competition from overseas took the shine off of these tech superstars.

However, both companies have reinvented themselves, and now they've begun to thrive. IBM, which transformed itself into a cloud computing giant, has gained nearly 45% over the past 12 months. The stock is up nearly 10% since beating earnings and revenue estimates on Jan. 19.

Hewlett Packard Enterprise (HPE) , a lean descendant of Hewlett Packard, has gained nearly 80% over the past 12 months. Not to be confused with the manufacturer of computers and printers HPQ (HPQ) , HPE is focused on networking, storage, and services.

When HPE reports earnings next week, will its results echo IBM's impressive performance? HPE is scheduled to report after the close on Feb. 23.

IBM's chart is easy to decipher; it's a bullish channel that features a series of higher highs (HH) and higher lows (HL). The stock is trading on the high side of its channel, and is overbought (arrow) according to its RSI (relative strength index) indicator.

A move to the lower end of the channel, currently near $175, would alleviate this overbought condition and create an ideal entry point on a dip.

Source: TradeStation

HPE's chart also features higher lows and higher highs, but has recently flattened out. However, the stock is gaining momentum. HPE has already climbed 10% this month and is on the verge of reaching a fresh high. Despite the stock's recent rally, its RSI indicator is still in neutral territory.

Source: TradeStation

If HPE sells off after earnings, I'd be a buyer. I'd look to enter in the area between $20.50 and $22. The stock has a cluster of support levels in that area (dotted lines).

With a market capitalization of $40.5 billion, HPE is by far the smaller of the two companies. HPE is also far nimbler, as it's demonstrated in a series of recent transactions. In just the past few months, HPE has purchased several companies and sold its software business for $8.8 billion. HPE's size and flexibility give it an advantage over IBM, which currently has a market cap of $174 billion.

Despite their recent gains, both names are reasonably valued. IBM is priced at 14.65x earnings, while HPE trades at 13.37x earnings. Of the two, I think HPE has greater potential, but I'd buy either stock on a dip.

(Jim Cramer and the AAP team hold positions in Apple and HPE for their Action Alerts PLUS Charitable Trust Portfolio . Want to be alerted before Cramer buys or sells AAPL and HPE? Learn more now.)

At the time of publication, Ed Ponsi had no positions in the stocks mentioned.

Action Alerts PLUS, which Jim Cramer co-manages as a charitable trust, is long AAPL and HPE.

More from Investing

Inside Carnival's Mind Blowing New Horizon Cruise Ship (Video)

Inside Carnival's Mind Blowing New Horizon Cruise Ship (Video)

Neel Kashkari: The Heart of Our Financial System Is More Radioactive Than Ever

Neel Kashkari: The Heart of Our Financial System Is More Radioactive Than Ever

McDonald's Criticized for Not Doing More in Wake of Sexual Harassment Claims

McDonald's Criticized for Not Doing More in Wake of Sexual Harassment Claims

Finding Stocks Right for You: Cramer's 'Mad Money' Recap (Friday 8/25/18)

Finding Stocks Right for You: Cramer's 'Mad Money' Recap (Friday 8/25/18)

Jim Cramer: The 10-Year Yield Could Go to 2.75%

Jim Cramer: The 10-Year Yield Could Go to 2.75%