improve quantized error checking for structured kernels (#71928)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/71928
Test Plan: Imported from OSS
Reviewed By: wconstab, bhosmer
Differential Revision: D33823417
Pulled By: bdhirsh
fbshipit-source-id: e894b9724833b77b12963cc4bf194bc6ce526ad9
(cherry picked from commit 6be10b79e7b3ff59aa8d6ca7cf86fc73f545933a)