Not sure if this is what you're looking for exactly, but I've got two Arcade/MAME cabinets side by side, both setup as independent cabinets. Using RetroArch w/ the FBNeo Core, I can get various MAME game running in 3/4 player mode across the two cabinets. You have to enable the advanced settings menu in RetroArch, then tell each RetroArch install which player slots to 'grab' when they connect.
I have Cabinet 1 grab players 1 & 3, and Cabinet 2 grab 2 and 4. This is so if I link up 2 player games, it still works. (like Marble Madness or something - one trackball on each cabinet).
RetroArch with the default netplay code assumes 1 player for each install (cabinet / computer), so first Retroarch to 'host' the game is player 1, then the next to join is player 2, next player 3, etc... It's not programmed to allow player 2 on cabinet 1 join, or player 2 on cabinet 2 join with the default settings. I guess it assumes everyone is alone and using the internet. At least the options are there in the advanced settings.
This works great, but is a little clunky to setup. I haven't tried any driving/racing games this way, but I do have Golden Axe, X-Men, Simpsons, Gauntlet, and a bunch of others working in 4 player mode this way. (I have a 3rd cabinet in a state of disrepair right now - if I fix / finish it, in theory I could get a 6-player X-man game running using the same methodology - make it request players 5 and 6 basically).
Edit - Launchbox / Bigbox front end has RetroArch netplay built right into the front end, so its easy to host/join games this way too. Don't have to use RetroArch's horrible interface, or command line once you get it all figured out.