This restores the behavior that existed prior to #16235 for setting OOMKilled, while retaining the additional benefits it introduced around emitting the oom event. This also adds a test for the most obvious OOM cases which would have caught this regression. Fixes #18510 Signed-off-by: Euan <euank@amazon.com> Upstream-commit: 0b5131444df83eb1e9fe4cfc6bfbf85314e089dc Component: engine