Skip to content

Commit 1f64ec6

Browse files
committed
Accept alternate spellings of __sparcv7 and __sparcv8.
Apparently some versions of gcc prefer __sparc_v7__ and __sparc_v8__. Per report from Waldemar Brodkorb.
1 parent 4200a92 commit 1f64ec6

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/include/storage/s_lock.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -384,12 +384,12 @@ tas(volatile slock_t *lock)
384384
: "=r"(_res), "+m"(*lock)
385385
: "r"(lock)
386386
: "memory");
387-
#if defined(__sparcv7)
387+
#if defined(__sparcv7) || defined(__sparc_v7__)
388388
/*
389389
* No stbar or membar available, luckily no actually produced hardware
390390
* requires a barrier.
391391
*/
392-
#elif defined(__sparcv8)
392+
#elif defined(__sparcv8) || defined(__sparc_v8__)
393393
/* stbar is available (and required for both PSO, RMO), membar isn't */
394394
__asm__ __volatile__ ("stbar \n":::"memory");
395395
#else
@@ -402,13 +402,13 @@ tas(volatile slock_t *lock)
402402
return (int) _res;
403403
}
404404

405-
#if defined(__sparcv7)
405+
#if defined(__sparcv7) || defined(__sparc_v7__)
406406
/*
407407
* No stbar or membar available, luckily no actually produced hardware
408408
* requires a barrier. We fall through to the default gcc definition of
409409
* S_UNLOCK in this case.
410410
*/
411-
#elif defined(__sparcv8)
411+
#elif defined(__sparcv8) || defined(__sparc_v8__)
412412
/* stbar is available (and required for both PSO, RMO), membar isn't */
413413
#define S_UNLOCK(lock) \
414414
do \

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy