[libc-commits] [PATCH] D144506: [libc] Implement ntohl and ntohs

Raman Tenneti via Phabricator via libc-commits libc-commits at lists.llvm.org
Tue Feb 21 17:29:07 PST 2023


rtenneti updated this revision to Diff 499333.
rtenneti added a comment.

+ Added explicit check for IS_LITTLE to do the swap.
+ Added a test to verify htonl(ntohl(orig)) == orig.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D144506/new/

https://reviews.llvm.org/D144506

Files:
  libc/src/network/ntohl.cpp
  libc/src/network/ntohs.cpp
  libc/test/src/network/CMakeLists.txt
  libc/test/src/network/htonl_test.cpp
  libc/test/src/network/htons_test.cpp
  libc/test/src/network/ntohl_test.cpp
  libc/test/src/network/ntohs_test.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D144506.499333.patch
Type: text/x-patch
Size: 4026 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libc-commits/attachments/20230222/3fc280a6/attachment-0001.bin>


More information about the libc-commits mailing list