From 6ca20f85cf0890431f4a2f0bc993d733ccb30bb2 Mon Sep 17 00:00:00 2001 From: Paolo Carlini Date: Mon, 7 May 2007 20:37:15 +0000 Subject: [PATCH] stl_algobase.h: Do not include . 2007-05-07 Paolo Carlini * include/bits/stl_algobase.h: Do not include . (copy(const _Tp*, const _Tp*, _Tp*), __copy_b(const _Tp*, const _Tp*, _Tp*)): Use __builtin_memmove. (__fill_aux): Use __builtin_memset. (equal(const _Tp*, const _Tp*, const _Tp*), lexicographical_compare(const unsigned char*, const unsigned char*, const unsigned char*, const unsigned char*)): Use __builtin_memcmp. * include/bits/valarray_array.h: Do not include . (_Array_default_ctor<, true>::_S_do_it): Use __builtin_memset. (_Array_copy_ctor<, true>::_S_do_it, _Array_copier<, true>::_S_do_it): Use __builtin_memcpy. * include/ext/algorithm (__lexicographical_compare_3way(const unsigned char*, const unsigned char*, const unsigned char*, const unsigned char*)): Use __builtin_memcmp. * testsuite/23_containers/vector/requirements/dr438/ constructor_1_neg.cc: Adjust dg-error line number. * testsuite/23_containers/vector/requirements/dr438/ constructor_2_neg.cc: Likewise. From-SVN: r124512 --- libstdc++-v3/include/bits/valarray_array.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/libstdc++-v3/include/bits/valarray_array.h b/libstdc++-v3/include/bits/valarray_array.h index 84f9a749067a..128b9deae8d7 100644 --- a/libstdc++-v3/include/bits/valarray_array.h +++ b/libstdc++-v3/include/bits/valarray_array.h @@ -1,7 +1,8 @@ // The template and inlines for the -*- C++ -*- internal _Array helper class. -// Copyright (C) 1997, 1998, 1999, 2000, 2003, 2004, 2005, 2006, 2007 -// Free Software Foundation, Inc. +// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, +// 2006, 2007 +// Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -43,7 +44,6 @@ #include #include #include -#include #include _GLIBCXX_BEGIN_NAMESPACE(std) @@ -91,7 +91,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std) // For fundamental types, it suffices to say 'memset()' inline static void _S_do_it(_Tp* __restrict__ __b, _Tp* __restrict__ __e) - { std::memset(__b, 0, (__e - __b) * sizeof(_Tp)); } + { __builtin_memset(__b, 0, (__e - __b) * sizeof(_Tp)); } }; template @@ -160,7 +160,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std) inline static void _S_do_it(const _Tp* __restrict__ __b, const _Tp* __restrict__ __e, _Tp* __restrict__ __o) - { std::memcpy(__o, __b, (__e - __b)*sizeof(_Tp)); } + { __builtin_memcpy(__o, __b, (__e - __b) * sizeof(_Tp)); } }; template @@ -267,7 +267,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std) { inline static void _S_do_it(const _Tp* __restrict__ __a, size_t __n, _Tp* __restrict__ __b) - { std::memcpy (__b, __a, __n * sizeof (_Tp)); } + { __builtin_memcpy(__b, __a, __n * sizeof (_Tp)); } }; // Copy a plain array __a[<__n>] into a play array __b[<>]