runtime: see whether gp==nil before checking preemption state
runtime: see whether gp==nil before checking preemption state

Recent we changed from using gFromTLS to using gFromSP, which apparently
sometimes returns nil. This causes crashes when dereferenced. Fix that
by not checking for preemption in the case that gFromSP returns nil.

Fixes #44679.

Change-Id: I0199ebe7cd113379c5fa35c27932d913df79092a
Reviewed-on: https://go-review.googlesource.com/c/go/+/297390
Trust: Jason A. Donenfeld <e7e312fea4c2c1aad2bb075d739111890e1ce08b@zx2c4.com>
Run-TryBot: Jason A. Donenfeld <e7e312fea4c2c1aad2bb075d739111890e1ce08b@zx2c4.com>
TryBot-Result: Go Bot <66cb808b70d30c07676d5e946fee83fd561249e5@golang.org>
Reviewed-by: Russ Cox <5ad239cb8a44f659eaaee0aa1ea5b94947abe557@golang.org>

nawawi/go,nawawi/go,golang/go,cloudflare/go,cloudflare/go,CAFxX/go,cloudflare/go,cloudflare/go,CAFxX/go,cloudflare/go,golang/go,nawawi/go,CAFxX/go,CAFxX/go,nawawi/go,CAFxX/go,CAFxX/go,golang/go,cloudflare/go,nawawi/go,golang/go,golang/go,nawawi/go,golang/go,CAFxX/go,cloudflare/go,nawawi/go,cloudflare/go,nawawi/go,golang/go,golang/go,CAFxX/go