Flush WDDM queue if on Windows

CUDA version showed very poor performance on Windows compared to Linux.
This was due to WDDM buffering GPU jobs before actually sending them to
the GPU for execution.
This was solved by calling cudaStreamQuery, which triggers a flush for
the WDDM queue.