From e22c90fa5d51636f7feb04e749da8bf31554869d Mon Sep 17 00:00:00 2001 From: Mateusz Jablonski Date: Thu, 16 Jan 2020 10:43:31 +0100 Subject: [PATCH] Make UNRECOVERABLE_IF more verbose in ULTs Change-Id: Ia16781be7deb12c2eac6802f5f2459186b99ee08 Signed-off-by: Mateusz Jablonski --- unit_tests/helpers/debug_helpers.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/unit_tests/helpers/debug_helpers.cpp b/unit_tests/helpers/debug_helpers.cpp index 9c2d7998bd..f7545bd5c9 100644 --- a/unit_tests/helpers/debug_helpers.cpp +++ b/unit_tests/helpers/debug_helpers.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2017-2019 Intel Corporation + * Copyright (C) 2017-2020 Intel Corporation * * SPDX-License-Identifier: MIT * @@ -7,12 +7,14 @@ #include "core/helpers/debug_helpers.h" -#include +#include +#include namespace NEO { void debugBreak(int line, const char *file) { } void abortUnrecoverable(int line, const char *file) { - throw std::exception(); + std::string message = "Abort was called at " + std::to_string(line) + " line in file " + file; + throw std::runtime_error(message); } -} // namespace NEO \ No newline at end of file +} // namespace NEO