1 |
cnh |
1.4 |
C $Header: /u/gcmpack/models/MITgcmUV/eesupp/src/memsync.F,v 1.3 1999/05/18 17:39:21 adcroft Exp $ |
2 |
|
|
C $Name: $ |
3 |
adcroft |
1.2 |
|
4 |
|
|
#include "CPP_EEOPTIONS.h" |
5 |
cnh |
1.1 |
|
6 |
|
|
SUBROUTINE MEMSYNC |
7 |
|
|
|
8 |
|
|
C /==========================================================\ |
9 |
|
|
C | SUBROUTINE MEMSYNC | |
10 |
|
|
C | o Place holder for memory sync routine | |
11 |
|
|
C |==========================================================| |
12 |
|
|
C | This routine is called wherever the code requires | |
13 |
|
|
C | that writes performed by one thread or process must | |
14 |
|
|
C | be guaranteed visible to other processes and or threads. | |
15 |
|
|
C | On SPARC this routine would implement a | |
16 |
|
|
C | asm("membar #LoadStore|#StoreStore"); | |
17 |
|
|
C | On ALPHA | |
18 |
|
|
C | asm("mb"); | |
19 |
|
|
C | Note: I have yet to show this is necessary although | |
20 |
|
|
C | the Memory Channel writes must need something like| |
21 |
|
|
C | this. | |
22 |
|
|
C \==========================================================/ |
23 |
adcroft |
1.3 |
IMPLICIT NONE |
24 |
cnh |
1.1 |
|
25 |
|
|
END |