Make sure you are on a system with WebGL 2.0 Compute enabled. Windows Google Chrome or Microsoft Edge Insider Channels with Command Line Switches: "--enable-webgl2-compute-context", "--use-angle=gl" and "--use-cmd-decoder=passthrough".
This demo sorts an array with selected number of elements by CPU and GPU, then compares each elapsed time.