Premonomorphisation discussion seems highly relevant, doesn't it?
There @mcy suggested to take inspiration from C++ which can
// Explicitly instantiate the template.
template void Foo<int>(int);
explicitly include particular template instantiations into a given .so
Extremely interested to know how the set of packages for Ubuntu 20.04.1 LTS is compiled.
I find it hard to believe this isn't done centrally in one big batch.