I have a large int array of 123 MB in size, and it is mainly used as follows:
private static int[] data = new int[32487834]; static int eval(int[] c) { int p = data[c[0]]; p = data[p + c[1]]; p = data[p + c[2]]; p = data[p + c[3]]; p = data[p + c[4]]; p = data[p + c[5]]; return data[p + c[6]]; }
eval() is called a lot (~ 50B times) with different c , and I would like to know if (and how) could speed it up.
I already use an insecure function with a fixed array that uses all processors. This is a C # port appraiser of RayW's TwoPlusTwo 7 maps . The C ++ version is slightly faster.
Can a GPU be used to speed this up?
performance c # gpu lookup
Sven
source share