1 //===-- Shared memory RPC client instantiation ------------------*- C++ -*-===//
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
9 #ifndef LLVM_LIBC_SRC___SUPPORT_RPC_RPC_CLIENT_H
10 #define LLVM_LIBC_SRC___SUPPORT_RPC_RPC_CLIENT_H
12 #include "shared/rpc.h"
13 #include "shared/rpc_opcodes.h"
15 #include "src/__support/CPP/type_traits.h"
16 #include "src/__support/macros/config.h"
18 namespace LIBC_NAMESPACE_DECL
{
27 static_assert(cpp::is_trivially_copyable
<Client
>::value
&&
28 sizeof(Process
<true>) == sizeof(Process
<false>),
29 "The client is not trivially copyable from the server");
31 /// The libc client instance used to communicate with the server.
32 [[gnu::visibility("protected")]] extern Client client
asm("__llvm_rpc_client");
35 } // namespace LIBC_NAMESPACE_DECL