Although it is spelling mistakes, it might make an affects while reading docs.
Co-Authored-By: Nguyen Phuong An <AnNP@vn.fujitsu.com>
Signed-off-by: Kim Bao Long <longkb@vn.fujitsu.com>
Clang doesn't support adapting calling convention when converting a
non-capturing lambda into a function pointer, and it doesn't
support tagging a lambda with calling convention AFAICT. In
thd_windows.cc, we create the thread body lambda and pass it to
CreateThread(), which fails to build on clang because it cannot
convert the lambda into stdcall function. Note that this bug only
happens when building for x32 architecture. x64 is not affected because
there is only one standard x64 calling convention.
This change fixes this by moving the thread body logic into a private
static method and tagging it with WINAPI (which expands to __stdcall).
This commit adds a IDictionary<object, object> UserState member to the
ServerCallContext. Interceptors and call handlers can use this member to
pass per-call state between themselves.
Like other members of ServerCallContext, UserState is not thread-safe.
UserState is initialized on demand so that calls that don't use
UserState don't need to pay for it.
Closes https://github.com/grpc/grpc/issues/17759
Retire the old atomic_with_atm.h and atomic_with_std.h as they are not
needed anymore.
Introduce helper methods which call GPR_ATM_INC_ADD_THEN and
GPR_ATM_INC_CAS_THEN, and use them everywhere.
Also introduce AtomicIncrementIfNonzero, originally authored by
vjpai@. This is going to be used for completion queues.