I used to commute to work with a chum who rode his BMX bike while I rode my road bike. He was stronger than me, and he was faster than me.
If the two riders are of similar strength and fitness, I would give the edge to the road bike for anything over ~200 m. The riding position of aa BMX doesn't lend itself to cranking out power for any length of time, unless the rider is a training fanatic.