Refactor plugin setup and shutdown
This is based on !1106 (merged), so shouldn’t be merged until that’s been reviewed and merged.
This is a series of commits to add {setup,shutdown}_{async,finish}()
vfuncs to GsPluginClass
, and port all the plugins from using gs_plugin_setup()
to providing async setup vfuncs instead.
By making setup async, the setup of all the plugins can be done in parallel, which should speed up startup a little. I haven’t measured it, but by eye it feels no worse than before. My focus with this branch has been refactoring to make future refactoring (#1472) easier, rather than performance gains.
See the individual commit messages for details. The commits should be fairly logically split up, and it’s probably easier to review them sequentially rather than reviewing the diff for the entire branch.
The code will not build or run properly when one of these intermediate commits is checked out, as it’ll be half-way through the port. It should compile and run properly when on the final commit in the branch. I have smoketested that it does start up and shut down properly.
Helps: #1472