aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3/aclocal.m4
diff options
context:
space:
mode:
authorPaolo Carlini <pcarlini@unitus.it>2003-07-14 20:23:12 +0200
committerPaolo Carlini <paolo@gcc.gnu.org>2003-07-14 18:23:12 +0000
commitbda243ec50619e4b80e35a8c77a9ebc44647ca38 (patch)
tree11c82ea18a45d7f42a2a512635da67b8184d3c7a /libstdc++-v3/aclocal.m4
parent19948e32a8be1a439f58c2d34a7f0b03ec03b85c (diff)
downloadgcc-bda243ec50619e4b80e35a8c77a9ebc44647ca38.zip
gcc-bda243ec50619e4b80e35a8c77a9ebc44647ca38.tar.gz
gcc-bda243ec50619e4b80e35a8c77a9ebc44647ca38.tar.bz2
Nathan C.
2003-07-14 Paolo Carlini <pcarlini@unitus.it> Nathan C. Myers <ncm-nospam@cantrip.org> PR libstdc++/11378 * include/std/std_fstream.h (xsputn): Declare only. * include/bits/fstream.tcc (xsputn): Define, optimize for the always_noconv() case: when __n is sufficiently large flush the buffer and issue a direct write, if possible combining the two with writev in __basic_file<>::xsputn_2. * config/io/basic_file_stdio.h (__basic_file<>::xsputn_2): New, declare. * config/io/basic_file_stdio.cc (__basic_file<>::xsputn_2): Define. * acinclude.m4 (GLIBCXX_CHECK_WRITE): New macro, checking for the availability of writev in <sys/uio.h>. * configure.in: Call here. * acconfig.h: Add undef for the corresponding symbol. * aclocal.m4: Regenerate. * configure: Regenerate. * config.h.in: Regenerate. * testsuite/27_io/basic_filebuf/setbuf/char/3.cc: Tweak. * include/std/std_fstream.h (sync): Constify a variable. Co-Authored-By: Nathan C. Myers <ncm-nospam@cantrip.org> From-SVN: r69341
Diffstat (limited to 'libstdc++-v3/aclocal.m4')
-rw-r--r--libstdc++-v3/aclocal.m417
1 files changed, 17 insertions, 0 deletions
diff --git a/libstdc++-v3/aclocal.m4 b/libstdc++-v3/aclocal.m4
index b0cdfd9..f5677b8 100644
--- a/libstdc++-v3/aclocal.m4
+++ b/libstdc++-v3/aclocal.m4
@@ -2174,6 +2174,23 @@ AC_DEFUN(GLIBCXX_CHECK_POLL, [
fi
])
+dnl
+dnl Check whether writev is available in <sys/uio.h>.
+dnl
+
+AC_DEFUN(GLIBCXX_CHECK_WRITEV, [
+ AC_CACHE_VAL(glibcxx_cv_WRITEV, [
+ AC_TRY_COMPILE([#include <sys/uio.h>],
+ [struct iovec iov[2]; writev(0, iov, 0); ],
+ [glibcxx_cv_WRITEV=yes],
+ [glibcxx_cv_WRITEV=no])
+ ])
+ if test x$glibcxx_cv_WRITEV = xyes; then
+ AC_DEFINE(HAVE_WRITEV)
+ fi
+])
+
+
# Check whether LC_MESSAGES is available in <locale.h>.
# Ulrich Drepper <drepper@cygnus.com>, 1995.
#