Skip to content

Commit

Permalink
[shims] Force-inline new shims
Browse files Browse the repository at this point in the history
  • Loading branch information
lorentey committed Oct 7, 2020
1 parent 45fa32a commit 40bd3ba
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions Sources/_AtomicsShims/include/_AtomicsShims.h
Expand Up @@ -360,12 +360,14 @@ SWIFTATOMIC_DEFINE_TYPE(COMPLEX, DoubleWord, _sa_dword, uint64_t)
#error "Unsupported intptr_t bit width"
#endif // __INTPTR_WIDTH

static inline void _sa_retain_n(void *object, uint32_t n) {
SWIFTATOMIC_INLINE
void _sa_retain_n(void *object, uint32_t n) {
extern void *swift_retain_n(void *object, uint32_t n);
swift_retain_n(object, n);
}

static inline void _sa_release_n(void *object, uint32_t n) {
SWIFTATOMIC_INLINE
void _sa_release_n(void *object, uint32_t n) {
extern void swift_release_n(void *object, uint32_t n);
swift_release_n(object, n);
}
Expand Down

0 comments on commit 40bd3ba

Please sign in to comment.