Are flat handlebars stable at high speed? I live in a mountainous area, and so there are lots of opportunities for descending at high speed. I currently have a bike with drop bars, and when in the drops, I feel very stable doing this.

I am now in the market for a new bike, and I'm thinking I might like to switch to flat bars. However, on my current bike, I feel quite unstable on the tops at speed. Can the new bike (it is a custom frame) be designed to feel and be stable at high speed (say, over 40 MPH) with flat bars?
First off, understand that the geometry of the bike affects stability, especially the "marriage" between head angle and fork rake.  Adjusting these parameters (which can really only be "adjusted" by the frame builder) has a very dramatic effect on stability.

Beyond that, the hand position has an effect in a couple of ways.  First, if the hand position is more forward, it tends to "pull" the steering tube straight, reducing "responsiveness" and making it easier to hold the front wheel straight, while a more rearward position will make the steering more responsive and maybe "twitchy".  Similarly, an outboard hand position will allow the arms to brace the bar more, while an inboard position allows less torque to be applied to the steering tube.  Finally, when riding on the drops one can (with a bar of a certain geometry) brace the lower arm against the corner of the top of the bar, adding more rigidity than would be present with just the hands on the drops.

(Note that weight distribution (eg, how forward/aft and high/low the rider's center of gravity is) also has an effect.  Riding on the drops or not affects this to a degree.)

But remember that rigidity does not equal control.  A "stable" bike will take a bump and re-balance itself more or less automatically, due to steering tube geometry, et al, somewhat independent of hand position.  It's good to have a bar that allows you to apply the "desired" amount of torque to the steering tube (based on your preference for responsiveness vs stability), but if all that's doing is letting you fight poor inherent bike stability that's not a good trade-off.