Re:“Shared libraries are not a good thing in general”
by yjftsjthsd-h on Saturday May 01, 2021 @10:07PM
(#27011781)
Isn't that just ABI stability with extra steps?
Re:“Shared libraries are not a good thing in general”
by jcelerier on Sunday May 02, 2021 @04:18AM
(#27013289)
it has the slight benefit of not corrupting your memory if your make an error
Re:“Shared libraries are not a good thing in general”
by nitrogen on Saturday May 01, 2021 @09:41PM
(#27011650)
I think the failure was to not realize it earlier and instead move to a more "message passing" + "error kernel" based approach for libraries where this is possible (which are surprisingly many) and use API stability only for the rest (except system libraries).
Sounds pretty sweet as far as composability is concerned, but there is the overhead caused by serialization and the loss of passing parameters in registers.
And even through keeping API stability is much easier then ABI stability I already ran into gotchas.
And that was simple stuff compared to what some of the more complex libraries do.
So I don't think ABI FFI stability ever had a good chance (outside of some very well maintained big system libraries where a lot of work is put into making it work).
I think the failure was to not realize it earlier and instead move to a more "message passing" + "error kernel" based approach for libraries where this is possible (which are surprisingly many) and use API stability only for the rest (except system libraries).
EDIT: Like use pipes to interconnect libraries and use well defined (but potential binary) message passing between them. Being able to reload libraries resetting all global state, or run multiple versions of them at the same time etc. But without question this isn't nice for small utility libraries or language frameworks and similar.