1. A system comprising: a first plurality of virtual machines belonging to a first overlay network; a second plurality of virtual machines belonging to a second overlay network, wherein the first and second pluralities of virtual machines operate in a plurality of host machines, each host machine comprising a managed physical routing element (MPRE), each MPRE for forwarding data packets between virtual machines in different overlay networks, wherein a particular MPRE is configured as a bridge for bridging packets between virtual machines that are in different overlay networks but in a same IP (internet protocol) subnet by using a pairing between an overlay network identifier and a link layer address, wherein (i) a logical interface of the particular MPRE is configured as a bridge logical interface for interfacing with a particular overlay network and (ii) the bridge logical interface is identified by an overlay network identifier for the particular overlay network, wherein a data message between virtual machines operating on a same host that are in different overlay networks but in a same IP subnet is forwarded by the particular MPRE to the data message's destination without exiting the host machine.