main
|
Last change
on this file was ea777aa, checked in by Alex Wilton <awilton@…>, 3 years ago |
|
Moved examples, include, build_default.properties, common.xml, and README out from dev.civl.com into the root of the repo.
git-svn-id: svn://vsl.cis.udel.edu/civl/trunk@5704 fb995dde-84ed-4084-dfe6-e5aef3e2452c
|
-
Property mode
set to
100755
|
|
File size:
1.2 KB
|
| Rev | Line | |
|---|
| [e3f356c] | 1 | !!!~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~!!!
|
|---|
| 2 | !!! Copyright (c) 2017-20, Lawrence Livermore National Security, LLC
|
|---|
| 3 | !!! and DataRaceBench project contributors. See the DataRaceBench/COPYRIGHT file for details.
|
|---|
| 4 | !!!
|
|---|
| 5 | !!! SPDX-License-Identifier: (BSD-3-Clause)
|
|---|
| 6 | !!!~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~!!!
|
|---|
| 7 |
|
|---|
| 8 | !For the case of a variable which is not referenced within a construct:
|
|---|
| 9 | !static data member should be shared, unless it is within a threadprivate directive.
|
|---|
| 10 | !
|
|---|
| 11 | !Dependence pair: counter@27:9 vs. counter@27:19
|
|---|
| 12 |
|
|---|
| 13 | module DRB086
|
|---|
| 14 | implicit none
|
|---|
| 15 | public :: A, foo
|
|---|
| 16 |
|
|---|
| 17 | integer, save :: counter
|
|---|
| 18 | integer, save :: pcounter
|
|---|
| 19 |
|
|---|
| 20 | type A
|
|---|
| 21 | integer :: counter
|
|---|
| 22 | integer :: pcounter
|
|---|
| 23 | end type
|
|---|
| 24 | !$omp threadprivate(pcounter)
|
|---|
| 25 | contains
|
|---|
| 26 | subroutine foo()
|
|---|
| 27 | counter = counter + 1
|
|---|
| 28 | pcounter = pcounter + 1
|
|---|
| 29 | end subroutine
|
|---|
| 30 | end module
|
|---|
| 31 |
|
|---|
| 32 | program DRB086_static_data_member_orig_yes
|
|---|
| 33 | use omp_lib
|
|---|
| 34 | use DRB086
|
|---|
| 35 | implicit none
|
|---|
| 36 |
|
|---|
| 37 | type(A) :: c
|
|---|
| 38 | c = A(0,0)
|
|---|
| 39 |
|
|---|
| 40 | !$omp parallel
|
|---|
| 41 | call foo()
|
|---|
| 42 | !$omp end parallel
|
|---|
| 43 |
|
|---|
| 44 | print *,counter,pcounter
|
|---|
| 45 | end program
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.