UnitTestFrameworkPkg: SampleGoogleTestGenerateException: Support AArch64

The SampleGoogleTestGenerateException GoogleTest sample previously
generated a CPU exception by performing an integer divide by zero. That
mechanism is X86-specific: the AArch64 architecture defines SDIV/UDIV by
zero to return zero rather than raising a synchronous abort, so the
sample produced no exception when built and run on AArch64 hosts and the
test failed due to the test assert instead of triggering an exception
through the framework.

This change replaces the divide-by-zero with a NULL pointer write
performed through a small volatile helper, which is expected to work on
all host systems.

The MSVC '/wd4723' build option is no longer needed because it was added
to silence the divide-by-zero compile-time warning.

Signed-off-by: Kun Qin <kun.qin@microsoft.com>
3 files changed