[libcxx][AIX][z/OS] Remove headers included via `_IBMCPP__`D127650 removed support for non-clang-based XL compilers, but left someof the headers used only by this compiler and included under the_
[libcxx][AIX][z/OS] Remove headers included via `_IBMCPP__`D127650 removed support for non-clang-based XL compilers, but left someof the headers used only by this compiler and included under the__IBMCPP__ macro. This change cleans this up by deleting these headers.Reviewed By: hubert.reinterpretcast, fanbo-mengDifferential Revision: https://reviews.llvm.org/D129491
show more ...
[libc++][NFC] Add MVS guard for locale_mgmt_zos.hThis header need not be included on non-z/OS IBM platforms (and indeedwill add nothing when it is), so add a guard. This let's us remove theheader
[libc++][NFC] Add MVS guard for locale_mgmt_zos.hThis header need not be included on non-z/OS IBM platforms (and indeedwill add nothing when it is), so add a guard. This let's us remove theheader without things breaking when shipping libc++ for AIX.Reviewed By: hubert.reinterpretcast, fanbo-mengDifferential Revision: https://reviews.llvm.org/D129493
[libcxx] Remove static inline and make use of _LIBCPP_HIDE_FROM_ABI in __support headersAfter feedback from D122861, do the same thing with some of the other headers. Try to move theheaders so the
[libcxx] Remove static inline and make use of _LIBCPP_HIDE_FROM_ABI in __support headersAfter feedback from D122861, do the same thing with some of the other headers. Try to move theheaders so they have a similar style and way of doing things.Reviewed By: ldionne, daltentyDifferential Revision: https://reviews.llvm.org/D124227
[SystemZ][z/OS] Fix warnings from unsigned int to long in 32-bit modeThis patch fixes the warnings which shows up when libcxx library started to be compiled in 32-bit mode on z/OS.More specificall
[SystemZ][z/OS] Fix warnings from unsigned int to long in 32-bit modeThis patch fixes the warnings which shows up when libcxx library started to be compiled in 32-bit mode on z/OS.More specifically, the assignment from unsigned int to time_t aka long was flags as follows: ```libcxx/include/c++/v1/__support/ibm/nanosleep.h:31:11: warning: implicit conversion changes signedness: 'unsigned int' to 'time_t' (aka 'long') [-Wsign-conversion] __sec = sleep(static_cast<unsigned int>(__sec)); ~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~libcxx/include/c++/v1/__support/ibm/nanosleep.h:36:36: warning: implicit conversion changes signedness: 'unsigned int' to 'long' [-Wsign-conversion] __rem->tv_nsec = __micro_sec * 1000; ~ ~~~~~~~~~~~~^~~~~~libcxx/include/c++/v1/__support/ibm/nanosleep.h:47:36: warning: implicit conversion changes signedness: 'unsigned int' to 'long' [-Wsign-conversion] __rem->tv_nsec = __micro_sec * 1000; ~ ~~~~~~~~~~~~^~~~~~3 warnings generated.```Here is a small test case illustrating the issue:```typedef long time_t ;unsigned int sleep(unsigned int );int main() { time_t sec = 0;#ifdef FIX sec = static_cast<time_t>(sleep(static_cast<unsigned int>(sec)));#else sec = sleep(static_cast<unsigned int>(sec));#endif}```clang++ -c -Wsign-conversion -m32 t.C```t.C:8:9: warning: implicit conversion changes signedness: 'unsigned int' to 'time_t' (aka 'long') [-Wsign-conversion] sec = sleep(static_cast<unsigned int>(sec)); ~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~Reviewed By: ldionne, #libc, Quuxplusone, MordanteDifferential Revision: https://reviews.llvm.org/D112837
[libcxx][AIX] Remove locale fallbacks for old OS levelsThese routines were add years ago during initial porting attempts to AIX and are mostly build hacks for routines which we're missing at the ti
[libcxx][AIX] Remove locale fallbacks for old OS levelsThese routines were add years ago during initial porting attempts to AIX and are mostly build hacks for routines which we're missing at the time, but are available now on recent AIX OS levels.Thus builds on modern AIX OS levels no longer need these and they cause problems if you try to build the library with a generic triple (i.e. powerpc-ibm-aix) as we'll pull them in and encounter duplicate definitions from the OS.Reviewed By: #libc, ldionneDifferential Revision: https://reviews.llvm.org/D110183
[libc++] Provide c++03 alternative for va_copy if available in xlocale.hSummary:If we are on c++03 mode for some reason, and __builtin_va_copy isavailable, then use it instead of error out on not
[libc++] Provide c++03 alternative for va_copy if available in xlocale.hSummary:If we are on c++03 mode for some reason, and __builtin_va_copy isavailable, then use it instead of error out on not having va_copyin 03 mode.Reviewed by: ldionneDifferential Revision: https://reviews.llvm.org/D100336
[libcxx][gardening] Re-order includes across libcxx.This commit alphabetizes all includes in libcxx. This is a NFC.This can also serve as a pseudo "announcement" for how we should order these hea
[libcxx][gardening] Re-order includes across libcxx.This commit alphabetizes all includes in libcxx. This is a NFC.This can also serve as a pseudo "announcement" for how we should order these headers going forward (note: double underscores go before other headers).Differential Revision: https://reviews.llvm.org/D102941
[SystemZ][z/OS] correct rc and errno within nanosleep()This patch fixes rc and errno within nanosleep(). It also updates __rem parameter as well it introduces cast to handle conversions from long i
[SystemZ][z/OS] correct rc and errno within nanosleep()This patch fixes rc and errno within nanosleep(). It also updates __rem parameter as well it introduces cast to handle conversions from long into unsigned int to avoid warnings.Reviewed By: MordanteDifferential Revision: https://reviews.llvm.org/D99373
[libc++][AIX] Initial patch to unblock the libc++ build on AIXThis path would unblock the build of libc++ library on AIX:1. Add _AIX guard for _LIBCPP_HAS_THREAD_API_PTHREAD2. Use uselocale to ac
[libc++][AIX] Initial patch to unblock the libc++ build on AIXThis path would unblock the build of libc++ library on AIX:1. Add _AIX guard for _LIBCPP_HAS_THREAD_API_PTHREAD2. Use uselocale to actually take the locale setting into account.3. extract_mtime and extract_atime mod needed for AIX. As stat structure on AIX uses internal structure st_timespec to store time for binary compatibility reason. So we need to convert it back to timespec here.4. Do not build cxa_thread_atexit.cpp for libcxxabi on AIX.Differential Revision: https://reviews.llvm.org/D97558
[SystemZ][z/OS] vasprintf fix libc++The aim is to use the correct vasprintf implementation for z/OS libc++, where a copy of va_list ap is needed. In particular, it avoids the potential that the ini
[SystemZ][z/OS] vasprintf fix libc++The aim is to use the correct vasprintf implementation for z/OS libc++, where a copy of va_list ap is needed. In particular, it avoids the potential that the initial internal call to vsnprintf will modify ap and the subsequent call to vsnprintf will use that modified ap.Differential Revision: https://reviews.llvm.org/D97473
[SystemZ][z/OS] Missing locale functions libc++The aim is to add the missing z/OS specific locale functions for libc++ (newlocale, freelocale and uselocale).Reviewed By: ldionne, #libc, curdeius
[SystemZ][z/OS] Missing locale functions libc++The aim is to add the missing z/OS specific locale functions for libc++ (newlocale, freelocale and uselocale).Reviewed By: ldionne, #libc, curdeiusDifferential Revision: https://reviews.llvm.org/D98044
[SystemZ][z/OS] Missing non-posix functions libc++The aim is to add missing non-posix functions for z/OS libc++ (strtod_l and strtof_l).Reviewed By: #libc, ldionneDifferential Revision: https:/
[SystemZ][z/OS] Missing non-posix functions libc++The aim is to add missing non-posix functions for z/OS libc++ (strtod_l and strtof_l).Reviewed By: #libc, ldionneDifferential Revision: https://reviews.llvm.org/D97051
[SystemZ][ZOS] Provide CLOCK_MONOTONIC alternativeWe need CLOCK_MONOTONIC equivalent implementation for z/OS within libc++. The default implementation is asserting.On z/OS the lack of 'clock_get
[SystemZ][ZOS] Provide CLOCK_MONOTONIC alternativeWe need CLOCK_MONOTONIC equivalent implementation for z/OS within libc++. The default implementation is asserting.On z/OS the lack of 'clock_gettime()' and 'time_point()' force us to look for alternatives.The current proposal is to use `gettimeofday()` for CLOCK_MONOTONIC which is also used in CLOCK_REALTIME. This will allow us to skip the assertion with compromised CLOCK_MONOTONIC implementation which will not guarantee to never go back in time because it will use `gettimeofday()` but only when it's set.Is this a good compromise for platforms which does not support monotonic clock?Hopefully this will spark the discussion and agreement how to proceed in this situation.Reviewed By: #libc, ldionne, hubert.reinterpretcastDifferential Revision: https://reviews.llvm.org/D93542
[libc++] Rename include/support to include/__supportWe do ship those headers, so the directory name should not be somethingthat can potentially conflict with user-defined directories.Differentia
[libc++] Rename include/support to include/__supportWe do ship those headers, so the directory name should not be somethingthat can potentially conflict with user-defined directories.Differential Revision: https://reviews.llvm.org/D95956