[sgen] Generate dynamically optimal internal allocator sizes