For long mountain bike races, eating on the bike is often a challenge. Accessing packaged food stored inside a hydration pack requires stopping. Most racers don’t want to stop to eat.
If you’re one of the lucky racers that can get away with using only bottles during a race, you can store food items in your jersey pockets. Many racers cannot use bottles-only in a race because their frame size only allows storage space for one small bottle and the distance between aid stations requires more fluid than one bottle can supply. These rider can carry an extra bottle in a jersey pocket, but often small sized jerseys won't hold a water bottle and all the extras needed for race day.
Some mountain bike riders have turned to using top tube storage boxes for food and a hydration pack for fluids. These boxes are popular with triathletes and multi-day, self-supported mountain bike riders. I did try one of these boxes but didn’t like the way it rubs on my top tube in rough terrain and though I liked the zipper access box better than Velcro access, the slapping of the zipper was annoying. Yes, I could put frame protectore on my top tube, but I didn't want to do that.
I prefer using a pack used by ultra-runners. The pack is made by Ultimate Direction and has generous pocket space built into the front of the shoulder straps. Two of the pockets have zippers and the other two are mesh nets with open tops. A photo of the Wink pack is below.
Depending on your personal bend, a top tube storage box or a hydration pack with shoulder strap storage may solve your food access problems.