c++ - SIMD or not SIMD - cross platform -


I need some idea how to write some of the parallel issues to the C ++ cross-platform implementation so that I can take advantage of it If possible, SIM (SSE, SP, etc.), I want to be able to switch between CIDD at run time. No SIMD.

How would you suggest me to face this problem (Of course I do not want to apply the problem several times for all possible options)

I can see how this can not be very easy to work with C ++ but I believe I'm missing something so far my idea looks like this ... A class CSTrim same area The array of will be used by many CSTEs Chana) I can achieve. Then using some funcents, I can create a fake lambda function which I need to implement on whole CSTrim. For example, I'm not expecting this code to be compiled cStream A; // something like the boat [1024] Seismide B; Sea Cream C; Zero Fu (for_each (AssignSIMD (c, MulSIMD (ADSIMD (A, B), A))); }

Where to increase the present indicator of e-mail streams, along with SIMD and without SIMD, it is responsible for inline the body of the Phantics.

Something like this: For example, I am not expecting this code, for which for_each (head and lieutenant; t & gt; f) {#ifdef USE_SIMD} (simdEnabled) real_for_each (f & Lt; true & gt; ()); // true means SIMD and #endif real_for_each (f false & gt; ()); }

Note that if SIM is enabled, then once it is checked and that it is around the main factor.

You might want to see the source of MacSTL libraries for some ideas in this area:


Comments

Popular posts from this blog

oracle - The fastest way to check if some records in a database table? -

php - multilevel menu with multilevel array -

jQuery UI: Datepicker month format -