ART: Shut down runtime in patchoat

When in a debug build, or under sanitization, shut down the runtime
after patching an image. This avoids tripping leak checks, while
keeping regular shutdown fast (similar to dex2oat).

Bug: 37728254
Test: m SANITIZE_HOST=true test-art-host
Change-Id: I812cf0c7e60745081b3c1c0e68d4631a43783ead
1 file changed