Add WGSL polyfill for inverse intrinsic.

This is used by Graphite, so a polyfill is necessary here. The
logic was cloned from MetalCodeGenerator and then updated to WGSL
syntax.

Change-Id: I9e87f880ba8925347345c75b7cd76fd27110714c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/736879
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
9 files changed