HTML/JS port of CUDA Occupancy Calculator http://news.developer.nvidia.com/2007/03/cuda_occupancy_.html