Ulrich Drepper wrote: >Richard Guenther wrote: > > >>Also, libgcc >>does _not_ know the machine - it only knows the -march it was compiled >>for. Inlining and transparently handling different sub-architecture just >>does not play together well. >> >> >Yes, libgcc doesn't know this. But the libgcc can be installed in the >correct place and the dynamic linker, which does in fact know what arch >is used, can make the decision. It's really pretty easy for those >platforms with sufficient flexibility. Use if cascades or indirect >jumps for the others, if necessary. > > Thanks for the explanation.
Frankly, my impression is that there is something to learn from this story: even if we decide to not proceed this route (now), it makes for a good example of what dynamic linking can make possible, maybe at the cost of some additional complexity but by far more sophisticated and powerful than traditional ways to approach this kind of problem. Paolo.