================ @@ -325,6 +325,44 @@ bool IsAccessibleMemoryRange(uptr beg, uptr size) { return true; } +bool TryMemCpy(void *dest, const void *src, uptr n) { + int sock_pair[2]; + if (pipe(sock_pair)) + return false; + + auto cleanup = at_scope_exit([&]() { + internal_close(sock_pair[0]); + internal_close(sock_pair[1]); + }); + + SetNonBlock(sock_pair[0]); ---------------- fmayer wrote:
We need to handle EAGAIN if we set Nonblock https://github.com/llvm/llvm-project/pull/112668 _______________________________________________ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits