[libc-commits] [PATCH] D148288: [libc] Update RPC interface for system utilities on th GPU
Joseph Huber via Phabricator via libc-commits
libc-commits at lists.llvm.org
Fri Apr 14 10:04:41 PDT 2023
jhuber6 added inline comments.
================
Comment at: libc/src/__support/OSUtil/gpu/io.cpp:19
+ rpc::Port port = rpc::client.open(rpc::PRINT_TO_STDERR);
+ port.send_n(msg.data(), msg.size() + 1);
}
----------------
lntue wrote:
> Does `send_n` still expect `msg.data()` is null-terminated?
We copy the entire buffer now, including the terminating null byte. Previously we had to add a null byte because we printed it in chunks. it worked alright but would be sub-optimal when multiple threads are involved.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D148288/new/
https://reviews.llvm.org/D148288
More information about the libc-commits
mailing list