[libc] Add endianness support
authorGuillaume Chatelet <gchatelet@google.com>
Fri, 16 Apr 2021 21:34:49 +0000 (21:34 +0000)
committerGuillaume Chatelet <gchatelet@google.com>
Fri, 16 Apr 2021 21:35:08 +0000 (21:35 +0000)
commit7e075ad0b261236dd0a01f0b5e01f3221b0700d7
tree3dfcda919d76088591d29f8232ced3f22274b9ec
parent5ebbb366c4a369740c3a3fe1f673e0e8c1902e60
[libc] Add endianness support

Add endianness detection support. This will be useful to implement `memcmp`.

Differential Revision: https://reviews.llvm.org/D100571
libc/src/__support/CMakeLists.txt
libc/src/__support/endian.h [new file with mode: 0644]
libc/test/src/CMakeLists.txt
libc/test/src/__support/CMakeLists.txt [new file with mode: 0644]
libc/test/src/__support/endian_test.cpp [new file with mode: 0644]