It depends on how much chain needs to be wrapped by the derailleur. Triples generally require a lot of chain wrap, which would call for a long-arm rear derailleur, but compact doubles can require just as much. Racing bikes with relatively close gearing don't need to wrap as much chain, and thus can use a shorter arm, and thus lighter, rear derailleur.