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:
984 bytes
|
| Line | |
|---|
| 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 | !Classic i-k-j matrix multiplication. No data race pairs.
|
|---|
| 9 |
|
|---|
| 10 |
|
|---|
| 11 | program DRB060_matrixmultiply_orig_no
|
|---|
| 12 | use omp_lib
|
|---|
| 13 | implicit none
|
|---|
| 14 |
|
|---|
| 15 | integer :: N,M,K, len, i, j, l
|
|---|
| 16 | real, dimension(:,:), allocatable :: a, b, c
|
|---|
| 17 |
|
|---|
| 18 | len = 100
|
|---|
| 19 | N=len
|
|---|
| 20 | M=len
|
|---|
| 21 | K=len
|
|---|
| 22 |
|
|---|
| 23 | allocate (a(N,M))
|
|---|
| 24 | allocate (b(M,K))
|
|---|
| 25 | allocate (c(K,N))
|
|---|
| 26 |
|
|---|
| 27 | !$omp parallel do private(j, l)
|
|---|
| 28 | do i = 1, N
|
|---|
| 29 | do l = 1, K
|
|---|
| 30 | do j = 1, M
|
|---|
| 31 | c(i,j) = c(i,j)+a(i,l)*b(l,j)
|
|---|
| 32 | end do
|
|---|
| 33 | end do
|
|---|
| 34 | end do
|
|---|
| 35 | !$omp end parallel do
|
|---|
| 36 |
|
|---|
| 37 | deallocate(a,b,c)
|
|---|
| 38 | end program
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.