PepsiCo's stock climbed by more than 4% on Thursday morning after the company reported stronger-than-expected earnings for the second quarter. The beverage and snack giant posted a revenue of $24.2 billion, surpassing the anticipated $24.0 billion. Adjusted earnings per share reached $2.22, exceeding the analyst consensus of $2.19. This positive performance was largely attributed to the strength of its international business, even as recent sales trends in its North American snack foods business had caused UBS and Bank of America to trim price targets earlier.

Costco, on the other hand, experienced a decline in its stock by about 4% in premarket trading, erasing earlier gains for the year. This dip occurred despite the warehouse retailer reporting overall earnings that beat Wall Street expectations. The concern among investors stemmed from moderating membership growth rates and comparable sales figures that were mixed. Specifically, two of its apparel chains, Old Navy and Athleta, underperformed in comparable sales estimates, while Gap and Banana Republic beat expectations.

Analysts had largely been bullish on PepsiCo, with an average price target just under $165, offering an upside of about 15% that would mark the stock's highest point since early March. However, concerns about recent sales in Pepsi's North American snack foods business had led to some price target adjustments. For Costco, while its premium valuation at around 47 times forward earnings is a point of contention compared to peers like Walmart and BJ's Wholesale, the company had seen its shares up 16% year-to-date prior to this recent decline.

Overall, the market reacted positively to PepsiCo's robust earnings and international performance, leading to a significant stock jump. Conversely, Costco's stock movement reflected investor concerns over slightly weaker comparable sales and membership growth, despite a solid overall earnings report. The differing reactions highlight the market's focus on specific growth metrics for these retail giants.