Here is how I ended up doing it.
I first further decomposed the schematic so that no sheet spans more than one board.
Note that due to lack of space I had to relocate components on separate boards until things fit in the available space.
There was no way to know ahead of time which component goes on which board beforehand, so there go any top-down "just decide where your stuff will be placed before you start" design fantasies.
I then replaced all the global nets with hierarchical labels. This applies especially to all power nets (3V3, 5V, GND, etc.). This was excruciatingly boring and took a long time to do manually, about half a day or 8 hours. (Maybe one day I'll write some code to parse the schematic S-expressions in a real language to be able to do that programmatically next time.)
Then I connected the connectors of each board to the subcircuits of that board only.
In the end you get for example four ground nets PCB0/GND, PCB1/GND, PCB2/GND, PCB3/GND, four 3V3 nets PCB0/3V3, PCB1/3V3 etc.
I made good use of the menu option that allows you to mass-convert labels from one type to the other (e.g. global to hierarchical.)
Once I did that I was able to finally see that needs to be routed in the PCB editor rat's nest.
One important thing that was useful is that I used local labels to connect connector pins to subcircuit pins.
I wasn't able to use a sheet for defining the connector pinouts, KiCAD was complaining about multiple labels per net, but maybe there is a way to do it using local labels.
A few improvements to KiCAD come to mind though:
- Power symbols that create local, not global nets. This way you can have ground symbols that look like ground and not just a square box with a "GND" sign as seen below.
- Selection filters in the schematic editor to select only local/global labels, only power symbols, etc. That will make the job of extracting subcircuits and making them into sheets not using global nets much easier.
- An option for automatically invoking and laying out the pins of a hierarchical sheet instance
- An option for sorting the above
- Another option for automatically updating the pin directions (in/out/bidirectional) even if it's just cosmetic