Skip to content

Commit

Permalink
[kalmar-omp] Add OpenUH OpenMP test-suite
Browse files Browse the repository at this point in the history
  • Loading branch information
lyh-kernel-MCW committed Nov 25, 2015
1 parent 3a99ceb commit bb454c7
Show file tree
Hide file tree
Showing 149 changed files with 14,633 additions and 0 deletions.
34 changes: 34 additions & 0 deletions OpenMP3.1_Validation/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
Copyright (c) 2011, 2012
University of Houston System

All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:

o Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.

o Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.

o Neither the name of the University of Houston System nor the names of its
contributors may be used to
endorse or promote products derived from this software without specific
prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.


222 changes: 222 additions & 0 deletions OpenMP3.1_Validation/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,222 @@
# General Makefile containing all the necessary compiler flags for the tests

# modify CC and CFLAGS for OpenMP C compilers
# modify FC and FFLAGS for OpenMP Fortran compilers


# Content:
#########################################################

# 1. Basic usage
# 2. General testsuite settings
# 3. Compiler selection and Flags

#########################################################


#########################################################
# 1. Basic usage
#########################################################
# make ctest generate c test "ctest"
# make ftest generate fortran test "ftest"
# make clean removes all sources and binaries
# make cleanall removes sources,binaries and logfiles


#########################################################
# 2. General testsuite settings
#########################################################

# For general testsuite settings see the configuration file
# ompts.conf

#########################################################
# 3. Compiler selection and Flags
#########################################################

# GNU Compiler
CC = gcc
CFLAGS = -fopenmp -lm -O3
CFLAGS = -fopenmp -lm -O3
FC = gfortran
FFLAGS = -fopenmp -lm
FFLAGS = -fopenmp -lm -O3


# Fujitsu Compilers:
#CC = fcc
#CFLAGS = -KOMP,fast_GP2=2
#FC=frt
#FFLAGS=-KOMP,fast_GP2=2 -w -Am -X9 -Fixed


# PGI compilers
#CC = pgcc
#CFLAGS = -mp
#CFLAGS = -mp -DVERBOSE
#CFLAGS = -fast -mp

#FC = pgf90
#FFLAGS = -fast -mp
#FFLAGS = -mp -g


# Intel compilers:
#CC = icc
#CFLAGS = -O3 -ip -openmp
#CFLAGS = -Wall -O0 -openmp
#CFLAGS = -openmp -lm
#CFLAGS = -openmp -lm -DVERBOSE

#FC = ifort
#FFLAGS = -openmp -lm -fpp

# Omni compilers:
#CC = ompcc
#CFLAGS = -O3 -lm


# Assure compilers:
#CC = assurec
#CFLAGS = -O3 -WApname=project -DUSE_ASSURE=1
#FC =
#FFLAGS =

# NEC:
#CC = c++
#CC = sxc++
#CFLAGS = -Popenmp

#FC=sxf90
#FFLAGS= -Popenmp


# Hitachi:
#CC = xcc
#CFLAGS = -O4 -pvec +Op -parallel -omp
#FC =
#FFLAGS =


# SGI:
#CC = cc
#CFLAGS = -mp -lm
#FC =
#FFLAGS =


# IBM compilers:
#CC = xlc_r
#CFLAGS = -qsmp=omp -lm


#FC=xlf90_r
#FFLAGS=-qsmp=omp -qfixed=132 -qlanglvl=extended


# SUN compilers
#CC = cc
#CFLAGS = -fast -xopenmp -lm

#FC =f90
#FFLAGS = -xopenmp -fast -lm


# open64 compilers
# remark: -I. was a workaround because the installation came without omp.h file
#CC = opencc
#CFLAGS = -O0 -openmp -lm -I. -lomp -lpthread
#CFLAGS = -O0 -openmp -lm -I /home/matthew/opt/usr/include -lpthread
#CFLAGS = -openmp -lm

#FC = openf90
#FFLAGS = -O0 -openmp -lm -lomp -lpthread


#Pathscale Compiler
#CC = pathcc
#CFLAGS = -mp -Ofast -lm

#FC=pathf90
#FFLAGS= -mp -Ofast -lm


#OpenUH Compiler
#CC = uhcc
#CFLAGS = -mp

#FC = uhf90
#FFLAGS = -mp

#########################################################################

help:
@echo "OpenMP Validation Suite, v3.0"
@echo "(C) University of Stuttgart, University of Houston"
@echo ""
@echo "Do make [rule], where rule may be one of:"
@echo " ctest"
@echo " Build and run the OpenMP/C validation tests."
@echo " ftest"
@echo " Build and run the OpenMP/Fortran validation tests."
@echo " print_compile_options"
@echo " Display the default compiler and compiler options being tested"
@echo " cleansrcs"
@echo " Remove sources generated from the templates"
@echo " cleanbins"
@echo " Remove executables from bin/ directory"
@echo " cleanouts"
@echo " Remove all *.out files from bin/ directory"
@echo " cleanlogs"
@echo " Remove all *.log files from bin/ directory"
@echo " clean"
@echo " Remove all sources and executables from bin/ directory"
@echo " cleanall"
@echo " Remove the entire bin/ directory"

omp_my_sleep:
mkdir -p bin/c
cp omp_my_sleep.h bin/c/
omp_testsuite: omp_testsuite.h
mkdir -p bin/c
cp omp_testsuite.h bin/c/
omp_testsuite.h: ompts-c.conf c/*
./ompts_makeHeader.pl -f=ompts-c.conf -t=c
.c.o: omp_testsuite omp_my_sleep
$(CC) $(CFLAGS) -c $<

ctest: omp_my_sleep omp_testsuite
./runtest.pl --lang=c testlist-c.txt

ftest:
mkdir -p bin/fortran
cp omp_testsuite.f bin/fortran
cp omp_my_sleep.f bin/fortran
./runtest.pl --lang=fortran testlist-f.txt

print_compile_options:
@echo "-------------------"
@echo "C compiler"
@echo "-------------------"
@echo "compilation: $(CC) $(CFLAGS)"
@$(CC) --version
@echo "-------------------"
@echo "Fortran compiler"
@echo "-------------------"
@echo "compilation: $(FC) $(FFLAGS)"
@$(FC) --version

cleansrcs:
find bin/ -iname "*.[cf]" -exec rm {} \;
cleanbins:
find bin/ -perm /a+x -type f -exec rm {} \;
cleanouts:
find bin/ -iname "*.out" -exec rm {} \;
cleanlogs:
find bin/ -iname "*.log" -exec rm {} \;

clean: cleansrcs cleanbins

cleanall:
rm -rf bin/

Loading

0 comments on commit bb454c7

Please sign in to comment.