This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: [Patch / RFA] Use builtins for the classification macros
On Mon, 26 Nov 2007, Paolo Carlini wrote:
> Hi,
> > On Mon, 26 Nov 2007, Paolo Carlini wrote:
> >> Hi,
> >>
> >> I'm finishing testing on x86_64-linux this patch: in my experiments, we
> >> get optimal code generation for constant arguments and we shave a couple
> >> of K of templates from a very used header. Can you imagine anything
> >> wrong with it? (I'm explicitly adding Richard in CC, as middle-end
> >> maintainer).
> >>
> > This should work. Even in the original sources we eventually
> > dispatch to gcc builtins dependent on libc implementation details.
> >
> Thanks Richard. I just noticed that, with it, we get an ICE in
> expr_size, at explow.c:249 (instead of the expected error), on the
> testcase of libstdc++/25913:
>
> #include <cmath>
> #include <string>
>
> struct employee
> : private std::string
> {
> };
>
> struct manager
> : public employee
> {
> };
>
> bool isnormal(const employee& e)
> {
> return false;
> }
>
> int main()
> {
> manager m;
> bool b = isnormal(m);
> }
>
> Can you look into that?
That works for me -- is that just with your patch applied?
Thx,
Richard.
--
Richard Guenther <rguenther@suse.de>
Novell / SUSE Labs
SUSE LINUX Products GmbH - Nuernberg - AG Nuernberg - HRB 16746 - GF: Markus Rex