Loading [MathJax]/extensions/tex2jax.js
Parallel numerical verification of the σ_odd problem  October 6, 2018
All Classes Namespaces Files Functions Variables Typedefs Macros
start_opencl.cpp
Go to the documentation of this file.
1 /* -*- coding: latin-1 -*- */
2 /** \file opencl/start_opencl.cpp (January 8, 2018)
3  * \brief
4  * Run an OpenCL program on some little numbers without printing,
5  * only to "start" OpenCL capabilities.
6  *
7  * GPLv3 --- Copyright (C) 2017, 2018 Olivier Pirson
8  * http://www.opimedia.be/
9  */
10 
11 // \cond
12 #include <cstdlib>
13 
14 #include <chrono>
15 #include <iostream>
16 // \endcond
17 
18 #include "../common/helper/helper.hpp"
19 
20 #include "opencl/opencl.hpp"
21 
22 
23 
24 /* ***********
25  * Prototype *
26  *************/
27 
28 void
30 
31 
32 
33 /* **********
34  * Function *
35  ************/
36 
37 void
39  std::cerr << "Usage: start_opencl" << std::endl;
40 
41  exit(EXIT_FAILURE);
42 }
43 
44 
45 
46 /* ******
47  * Main *
48  ********/
49 
50 int
51 main(int argc, const char* const[]) {
52  // Load primes table
54  std::cerr << "! Impossible to load \"" << sigmaodd::prime_filename << '"' << std::endl
55  << std::endl;
56  help_and_exit();
57  }
58 
59 
60  // Read command line parameters
61  if (argc > 1) {
62  help_and_exit();
63  }
64 
65 
66  // Main calculation
67  opencl::opencl_check_gentle_varsigma_odd(3, 1000001, 65536, false);
68 
69  return EXIT_SUCCESS;
70 }
std::set< nat_type > opencl_check_gentle_varsigma_odd(nat_type first_n, nat_type last_n, unsigned int opencl_nb_number, bool print_bad, bool print_time)
Check in the order all odd gentle numbers between first_n and last_n, and if print_bad then print all...
Definition: opencl.cpp:31
const std::string prime_filename
Default filename for the binary file "big_data/prime28.bin".
Definition: primes.cpp:35
bool read_primes_table()
Read the binary file prime_filename to fill the table with all primes < 2^28. This table must be read...
Definition: primes.cpp:241
int main(int argc, const char *const [])
Implementation of the OpenCL parallel algorithms presented in the report.
void help_and_exit()