Click here to Skip to main content
15,896,207 members
Articles / Programming Languages / Visual C++ 9.0

SFMT in Action: Part I – Generating a DLL Including SSE2 Support

Rate me:
Please Sign up or sign in to vote.
4.45/5 (4 votes)
28 Apr 2009CPOL22 min read 68.6K   741   21  
An approach for using the SFMT (SIMD-oriented Fast Mersenne Twister) random number generator algorithm.
/** 
 * modified by Emre �zg�r �nce (emre_lineus@yahoo.com)
 *
 * Original implementation: 	
 * Mutsuo Saito (Hiroshima University) and Makoto Matsumoto (Hiroshima University)
 * Copyright (C) 2006, 2007 Mutsuo Saito, Makoto Matsumoto and Hiroshima
 * University. All rights reserved.
 * The (modified) BSD License is applied to this software, see Original License/LICENSE.txt
 */

#ifndef SFMT_PARAMS11213_H
#define SFMT_PARAMS11213_H

#define POS1	68
#define SL1	14
#define SL2	3
#define SR1	7
#define SR2	3
#define MSK1	0xeffff7fbU
#define MSK2	0xffffffefU
#define MSK3	0xdfdfbfffU
#define MSK4	0x7fffdbfdU
#define PARITY1	0x00000001U
#define PARITY2	0x00000000U
#define PARITY3	0xe8148000U
#define PARITY4	0xd0c7afa3U

#define IDSTR	"SFMT-11213:68-14-3-7-3:effff7fb-ffffffef-dfdfbfff-7fffdbfd"

#endif /* SFMT_PARAMS11213_H */

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Founder Parola Bilgi Teknolojileri Ltd.
Turkey Turkey
He was born in Bursa, Turkey in 1979, and still lives in this fascinating place.

He started programming with Fortran when he was at university and then has experienced with MS Visual Basic, Borland Delphi, Java, C++ and C#.

He developed database based several client-server and multi-tier applications using OO concepts and OOP. He worked with Oracle, MySQL, MSSQL and Firebird RDBMS.

In the past, he worked on freetime image processing projects using OpenGL, DirectX, SDL technologies. He's interested in encryption/decryption and compression/decompression algorithms, random number generators and computational algorithms such as Monte Carlo Methods.

In 2011, he founded Parola Information Technology Ltd.

http://www.markanabak.com.tr is serviced by Parola Information Technology Ltd. It's a SAAS model for Intellectual Property sector.

Comments and Discussions