GPU code divided to analyze and kernels