Broadcom (AVGO  ) jumped higher following the company's Q2 results which showed the company beating analysts' expectations and issuing a stronger than expected forecast for the full year.

The company's results were in defiance of the broader semiconductor sector which is seeing a sharp slowing in sales as enterprise spending slows, while consumer tech spending is already contracting due to a combination of demand being pulled back forward, decreased spending on goods vs services, and inflation impacting consumer behavior. However, Broadcom managed to grow revenues by 25% and earnings by 40%.

Overall, shares are down by 21% YTD which is significantly better than the VanEck Semiconductor ETF (SMH  ) which is down by nearly 30% YTD. The combination of a falling stock price and earnings momentum has also resulted in valuations becoming quite attractive as the company sports a forward P/E of 12.9 along with a 3.1% dividend yield while also having faster earnings growth and higher margins than the S&P 500.

Inside the Numbers

In Q2, Broadcom reported $9.73 in earnings per share, topping expectations of $9.56 per share. Revenue also beat expectations at $8.46 billion vs $8.41 billion. Overall, earnings were up 40%, while revenue increased by 25% compared to last year.

The company noted growth across both of its major segments, driven by demand from cloud spending, service providers, and enterprise. Semiconductor products accounted for 78% of revenue, while infrastructure software contributed another 22%. Chip sales were up 32%, while infrastructure software increased by 5%.

The company expects this momentum to continue into the next quarter as spending in areas like data centers, broadband, and wireless continues to expand regardless of adverse economic conditions. Its a major supplier of wireless chips for the iPhone and its chips are also used for broadband, networking, storage, and industrial purposes.

It also increased its forecast for its next quarter, fueling the stock's gains in ensuing sessions. It sees a 20% increase in revenue in Q3, reaching $8.9 billion which was above analysts' expectations of $8.77 billion.