Currently IDs for
MachineBasicBlockss are implemented as static counters. I see two issues with that:
- It is not thread-safe
- IDs do not get reset after a compiler run
I propose we add a (possibly templated) ID generator to the
PassRunner. Since each compiler run has its own PassRunner instance and all passes run on the same thread, its thread-safe. They also get reset by the default, since each run/instance creates new generator(s).