Skip to content

Commit b3a1f14

Browse files
author
bragadeesh
committed
clRNG initial beta release, first commit
0 parents  commit b3a1f14

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

89 files changed

+18104
-0
lines changed

.gitignore

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
*.suo
2+
Debug
3+
Release
4+
x64
5+
*.opensdf
6+
7+
# Compiled Object files
8+
*.slo
9+
*.lo
10+
*.o
11+
12+
# Compiled Dynamic libraries
13+
*.so
14+
*.dylib
15+
16+
# Compiled Static libraries
17+
*.lai
18+
*.la
19+
*.a

CHANGELOG

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
2+
Name: clRNG
3+
Version: 1.0 Beta
4+
Release Date: April 2015
5+
6+
ChangeLog:
7+
8+
____________
9+
Current Version:
10+
* This is the initial beta release of clRNG
11+

LICENSE

+68
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
2+
Copyright (c) 2015 Advanced Micro Devices, Inc.
3+
All rights reserved.
4+
5+
Redistribution and use in source and binary forms, with or without
6+
modification, are permitted provided that the following conditions
7+
are met:
8+
9+
1. Redistributions of source code must retain the above copyright
10+
notice, this list of conditions and the following disclaimer.
11+
12+
2. Redistributions in binary form must reproduce the above copyright
13+
notice, this list of conditions and the following disclaimer in the
14+
documentation and/or other materials provided with the distribution.
15+
16+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
17+
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
18+
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
19+
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
20+
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
21+
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
22+
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23+
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24+
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25+
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
26+
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27+
28+
29+
***********************************************************************
30+
clRNG uses the following software with their
31+
corresponding licenses printed below:
32+
***********************************************************************
33+
34+
Random123 software
35+
https://www.deshawresearch.com/resources_random123.html
36+
37+
Copyright 2010-2011, D. E. Shaw Research.
38+
All rights reserved.
39+
40+
Redistribution and use in source and binary forms, with or without
41+
modification, are permitted provided that the following conditions are
42+
met:
43+
44+
* Redistributions of source code must retain the above copyright
45+
notice, this list of conditions, and the following disclaimer.
46+
47+
* Redistributions in binary form must reproduce the above copyright
48+
notice, this list of conditions, and the following disclaimer in the
49+
documentation and/or other materials provided with the distribution.
50+
51+
* Neither the name of D. E. Shaw Research nor the names of its
52+
contributors may be used to endorse or promote products derived from
53+
this software without specific prior written permission.
54+
55+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
56+
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
57+
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
58+
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
59+
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
60+
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
61+
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
62+
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
63+
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
64+
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
65+
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
66+
67+
68+
****************************************************************************

NOTICE

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
AMD clRNG
2+
Copyright (c) 2015 Advanced Micro Devices, Inc.
3+
4+
This product includes software developed at
5+
Advanced Micro Devices, Inc. (http://www.amd.com).
6+

README.md

+75
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
# clRNG Library
2+
3+
A library for uniform random number generation in OpenCL.
4+
5+
*Streams* of random numbers act as virtual random number generators.
6+
They can be created on the host computer in unlimited numbers, and then used
7+
either on the host or on computing devices by work items to generate random numbers.
8+
Each stream also has equally-spaced substreams, which are occasionally useful.
9+
The API is currently implemented for four different RNGs, namely the
10+
MRG31k3p, MRG32k3a, LFSR113 and Philox-4×32-10 generators.
11+
12+
#### Documentation
13+
14+
- [**HTML Documentation**
15+
(generated with Doxygen)](http://clmathlibraries.github.io/clRNG/htmldocs/index.html)
16+
- [**Tutorial Document**
17+
*clRNG*: A Random Number API with Multiple Streams for OpenCL](http://clmathlibraries.github.io/clRNG/docs/clrng-api.pdf)
18+
19+
## Building
20+
21+
Before configuring and building the library, make sure an OpenCL software
22+
development kit is available on your platform.
23+
24+
25+
### Under Linux
26+
27+
Run:
28+
29+
cmake src
30+
make
31+
make install
32+
33+
By default, `make install` packages the files necessary for distribution of the
34+
library in the `package` subdirectory.
35+
36+
37+
## Installing
38+
39+
The environment variable `CLRNG_ROOT` must be pointed to the root of the
40+
packaged files, or more specifically, the directory that contains the `include`
41+
and `cl` subdirectories.
42+
43+
Also make sure that the clRNG shared library can be found by the dynamic
44+
linker. The location of the shared library can depend on the platform. If you
45+
installed the library on a 64-bit Linux platform, it can normally be found
46+
under the `lib64` subdirectory of the installation directory.
47+
48+
49+
### Under Linux
50+
51+
On a 64-bit Linux platform with a Bash-compatible shell, if the current
52+
directory is that in which you ran `cmake src`, you can update the necessary
53+
environment variables by typing:
54+
55+
export CLRNG_ROOT=$PWD/package
56+
export LD_LIBRARY_PATH=$CLRNG_ROOT/lib64:$LD_LIBRARY_PATH
57+
58+
Then, you can check that everything works correctly by executing the unit tests
59+
with:
60+
61+
$CLRNG_ROOT/bin/CTest
62+
63+
64+
## Examples
65+
66+
Examples can be found in `src/client`.
67+
The compiled client program examples can be found under the `bin` subdirectory
68+
of the installation package (`$CLRNG_ROOT/bin` under Linux).
69+
Note that the examples expect an OpenCL GPU device to be available.
70+
71+
72+
## Building the documentation manually
73+
74+
The documentation can be generated by running `make` from within the `doc`
75+
directory. This requires Doxygen to be installed.

doc/Makefile

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
.PHONY: all html latex install clean
2+
3+
4+
all: html latex
5+
6+
html:
7+
doxygen clRNG.doxy
8+
9+
latex:
10+
$(MAKE) -C out/latex
11+
12+
install: html latex
13+
mkdir -p "$(PREFIX)/doc"
14+
install -d out/html "$(PREFIX)/doc"
15+
install --mode=0644 out/latex/refman.pdf "$(PREFIX)/doc"
16+
17+
clean:
18+
rm -rf out/html out/latex

doc/clRNG.bib

+130
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,130 @@
1+
@manual{iLEC08j,
2+
author = {P. L'Ecuyer},
3+
title = {{SSJ}: A {J}ava Library for Stochastic Simulation},
4+
note = {Software {user's} guide,
5+
available at \url{http://www.iro.umontreal.ca/~lecuyer}},
6+
institution = {D\'epartement d'Informatique et de Recherche
7+
Op\'erationnelle, Universit\'e de Montr\'eal},
8+
year = {2008},
9+
OPTannote = {}
10+
}
11+
12+
@ARTICLE {rLEC91a,
13+
AUTHOR="P. L'Ecuyer and S. C{\^o}t{\'e}",
14+
TITLE="Implementing a Random Number Package with Splitting Facilities",
15+
JOURNAL={ACM Transactions on Mathematical Software},
16+
VOLUME={17},
17+
NUMBER={1},
18+
YEAR={1991},
19+
PAGES={98--111} }
20+
21+
@article {rLEC99a,
22+
old = "rLEC97g",
23+
AUTHOR="P. L'Ecuyer",
24+
TITLE="Tables of Maximally Equidistributed Combined {LFSR} Generators",
25+
JOURNAL={Mathematics of Computation},
26+
VOLUME={68},
27+
NUMBER={225},
28+
PAGES={261--269},
29+
YEAR={1999}
30+
}
31+
32+
@article {rLEC99b,
33+
old = "rLEC97f",
34+
AUTHOR="P. L'Ecuyer",
35+
TITLE="Good Parameters and Implementations for
36+
Combined Multiple Recursive Random Number Generators",
37+
JOURNAL={Operations Research},
38+
VOLUME={47},
39+
NUMBER={1},
40+
PAGES={159--164},
41+
YEAR={1999}
42+
}
43+
44+
@INPROCEEDINGS {rLEC00b,
45+
AUTHOR="P. L'Ecuyer and R. Touzin",
46+
TITLE={Fast Combined Multiple Recursive Generators with Multipliers
47+
of the Form $a = \pm 2^q \pm 2^r$},
48+
BOOKTITLE={Proceedings of the 2000 Winter Simulation Conference},
49+
OPTeditor = {J. A. Joines and R. R. Barton and K. Kang
50+
and P. A. Fishwick},
51+
PUBLISHER="{IEEE} Press",
52+
ADDRESS= {Piscataway, NJ},
53+
YEAR={2000},
54+
PAGES={683--689} }
55+
56+
@article {rLEC02a,
57+
old = {rLEC01s},
58+
AUTHOR="P. L'Ecuyer and R. Simard and E. J. Chen and W. D. Kelton",
59+
TITLE="An Object-Oriented Random-Number Package with Many
60+
Long Streams and Substreams",
61+
JOURNAL={Operations Research},
62+
VOLUME={50},
63+
NUMBER={6},
64+
PAGES={1073--1075},
65+
YEAR={2002} }
66+
67+
@article{rLEC07b,
68+
OLD = {rLEC06b},
69+
author = {P. L'Ecuyer and R. Simard},
70+
title = {{TestU01}: A {C} Library for Empirical Testing of Random Number Generators},
71+
journal = {{ACM} Transactions on Mathematical Software},
72+
volume = {33},
73+
number = {4},
74+
pages = {Article 22},
75+
month = {August},
76+
year = {2007},
77+
OPTdoi = {http://doi.acm.org/10.1145/1268776.1268777},
78+
publisher = {ACM Press},
79+
address = {New York, NY, USA},
80+
OPTnote = {available at
81+
\url{http://www.simul.umontreal.ca/testu01/tu01.html}},
82+
}
83+
84+
@misc{rLEC14p,
85+
author = {P. L'Ecuyer and B. Oreshkin and R. Simard},
86+
title = {Random Numbers for Parallel Computers: Requirements and Methods},
87+
OPTjournal = {Mathematics and Computers in Simulation},
88+
xvolume = {},
89+
xnumber = {},
90+
xpages = {},
91+
year = {2014},
92+
\url = {http://www.iro.umontreal.ca/~lecuyer/myftp/papers/parallel-rng-imacs.pdf},
93+
note = {\url{http://www.iro.umontreal.ca/~lecuyer/myftp/papers/parallel-rng-imacs.pdf}}
94+
}
95+
96+
@inproceedings{rSAL11a,
97+
author = {Salmon, J. K. and Moraes, M. A. and Dror, R. O. and Shaw, D. E.},
98+
title = {Parallel random numbers: as easy as 1, 2, 3},
99+
booktitle = {Proceedings of the 2011 International Conference for High Performance Computing,
100+
Networking, Storage and Analysis},
101+
year = {2011},
102+
isbn = {978-1-4503-0771-0},
103+
Xlocation = {Seattle, Washington},
104+
pages = {16:1--16:12},
105+
articleno = {16},
106+
numpages = {12},
107+
OPTurl = {http://doi.acm.org/10.1145/2063384.2063405},
108+
OPTdoi = {10.1145/2063384.2063405},
109+
publisher = {ACM},
110+
address = {New York}
111+
}
112+
113+
@BOOK {sLAW14a,
114+
AUTHOR="A. M. Law",
115+
TITLE={Simulation Modeling and Analysis},
116+
EDITION={Fifth},
117+
PUBLISHER={McGraw-Hill},
118+
ADDRESS={New York},
119+
YEAR={2014} }
120+
121+
@InProceedings{vLEC07e,
122+
author = {P. L'Ecuyer},
123+
title = {Variance Reduction's Greatest Hits},
124+
booktitle = {Proceedings of the 2007 European Simulation and Modeling Conference},
125+
organization = {EUROSIS},
126+
address = {Ghent, Belgium},
127+
pages = {5--12},
128+
year = {2007}
129+
}
130+

0 commit comments

Comments
 (0)