Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
Grpc
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
tci-gateway-module
Grpc
Commits
33013ce9
Commit
33013ce9
authored
10 years ago
by
David Klempner
Browse files
Options
Downloads
Plain Diff
Merge pull request #1088 from nicolasnoble/windows-atm
Fixes for Windows atomics.
parents
17caeef7
b050ce96
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
include/grpc/support/atm.h
+1
-1
1 addition, 1 deletion
include/grpc/support/atm.h
include/grpc/support/atm_win32.h
+1
-1
1 addition, 1 deletion
include/grpc/support/atm_win32.h
include/grpc/support/port_platform.h
+12
-2
12 additions, 2 deletions
include/grpc/support/port_platform.h
with
14 additions
and
4 deletions
include/grpc/support/atm.h
+
1
−
1
View file @
33013ce9
...
...
@@ -83,7 +83,7 @@
#include
<grpc/support/atm_gcc_atomic.h>
#elif defined(GPR_GCC_SYNC)
#include
<grpc/support/atm_gcc_sync.h>
#elif defined(GPR_WIN32)
#elif defined(GPR_WIN32
_ATOMIC
)
#include
<grpc/support/atm_win32.h>
#else
#error could not determine platform for atm
...
...
This diff is collapsed.
Click to expand it.
include/grpc/support/atm_win32.h
+
1
−
1
View file @
33013ce9
...
...
@@ -51,7 +51,7 @@ static __inline gpr_atm gpr_atm_acq_load(const gpr_atm *p) {
static
__inline
gpr_atm
gpr_atm_no_barrier_load
(
const
gpr_atm
*
p
)
{
/* TODO(dklempner): Can we implement something better here? */
gpr_atm_acq_load
(
p
);
return
gpr_atm_acq_load
(
p
);
}
static
__inline
void
gpr_atm_rel_store
(
gpr_atm
*
p
,
gpr_atm
value
)
{
...
...
This diff is collapsed.
Click to expand it.
include/grpc/support/port_platform.h
+
12
−
2
View file @
33013ce9
...
...
@@ -43,11 +43,21 @@
#define GPR_ARCH_64 1
#define GPR_GETPID_IN_PROCESS_H 1
#define GPR_WINSOCK_SOCKET 1
#ifdef __GNUC__
#define GPR_GCC_ATOMIC 1
#else
#define GPR_WIN32_ATOMIC 1
#endif
#elif defined(_WIN32) || defined(WIN32)
#define GPR_ARCH_32 1
#define GPR_WIN32 1
#define GPR_GETPID_IN_PROCESS_H 1
#define GPR_WINSOCK_SOCKET 1
#ifdef __GNUC__
#define GPR_GCC_ATOMIC 1
#else
#define GPR_WIN32_ATOMIC 1
#endif
#elif defined(ANDROID) || defined(__ANDROID__)
#define GPR_ANDROID 1
#define GPR_ARCH_32 1
...
...
@@ -167,8 +177,8 @@
#endif
/* Validate platform combinations */
#if defined(GPR_GCC_ATOMIC) + defined(GPR_GCC_SYNC) + defined(GPR_WIN32) != 1
#error Must define exactly one of GPR_GCC_ATOMIC, GPR_GCC_SYNC, GPR_WIN32
#if defined(GPR_GCC_ATOMIC) + defined(GPR_GCC_SYNC) + defined(GPR_WIN32
_ATOMIC
) != 1
#error Must define exactly one of GPR_GCC_ATOMIC, GPR_GCC_SYNC, GPR_WIN32
_ATOMIC
#endif
#if defined(GPR_ARCH_32) + defined(GPR_ARCH_64) != 1
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment