This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: new concept checks and the 3.0 ABI
- To: Gabriel dot Dos-Reis at cmla dot ens-cachan dot fr (Gabriel Dos Reis)
- Subject: Re: new concept checks and the 3.0 ABI
- From: Joe Buck <jbuck at racerx dot synopsys dot com>
- Date: Fri, 6 Apr 2001 09:07:07 -0700 (PDT)
- Cc: jason_merrill at redhat dot com (Jason Merrill), bkoz at redhat dot com (Benjamin Kosnik), jbuck at synopsys dot COM (Joe Buck), libstdc++ at gcc dot gnu dot org
Jason Merrill <jason_merrill@redhat.com> writes:
> | What I think Joe is asking about is the libstdc++ ABI; in other words,
> | should people be able to expect that STL-using code compiled with 3.0 will
> | link with code compiled with 3.1? In other words, should we commit
> | ourselves to making only representation-compatible changes? Mark has
> | expressed the opinion that we should. I'm ambivalent.
Exactly.
Gaby writes:
> That is a very strong requirement I would like us not committed to.
Without such a requirement, claiming that the C++ ABI is stable is a joke,
and we should just drop the claim.
GCC team: "The C++ ABI is stable".
User: "OK, why doesn't my 3.1 code link against my 3.0 code?"
GCC team: "You used a class that we provided you, and we changed it."
User: "But I downloaded that class library as part of GNU C++."
GCC team: "Yes, but we thought of a new way to do concept checks, and
added some cool new refactoring".
User: "But you said the C++ ABI is stable."
GCC team: "But only for the compiler, not the library."
User: "But how can I write C++ without a library?"
So, Gaby, do you want us to tell the users that, if they want to ship
libraries that don't have to be recompiled each and every time we ship
a new compiler, they have to avoid all use of libstdc++?
Now, I do see your point -- it can be argued that we just aren't ready.
libstdc++-v3 still isn't stable enough to have its ABI frozen; we haven't
really taken advantage of factoring to reduce bloat from the STL (e.g.
using the same code for vector<T> for T's that are POD's, and having that
code in the library), and we don't really know if we're doing everything
the best way.
Maybe we'll have to aim for compiler ABI freeze in 3.0, library in 3.1
(in the sense of glibc: changes are backward compatible). But we do need
to think about how to achieve a library ABI freeze.