Skip to content

Commit 0b245df

Browse files
amielczaigcbot
authored andcommitted
Elevate unknown platform assert to error
Change the IGC_ASSERT to exit(1) to elevate the severity of a missing platform.
1 parent 151f84e commit 0b245df

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

IGC/Compiler/igc_workaround_linux.cpp

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ SPDX-License-Identifier: MIT
99
#include "igc_workaround.h"
1010
#include <string.h>
1111
#include <stdlib.h>
12-
#include "Probe/Assertion.h"
1312

1413
namespace IGC {
1514

@@ -152,7 +151,8 @@ void SetWorkaroundTable(SKU_FEATURE_TABLE *pSkuFeatureTable, CPlatform *platform
152151
its no longer based on platform */
153152
break;
154153
default:
155-
IGC_ASSERT(0);
154+
fprintf(stderr, "ERROR! Trying to select a workaround table for an unknown architecture. Aborting.\n");
155+
exit(1);
156156
break;
157157
}
158158
if (GFX_GET_CURRENT_PRODUCT(platform->getPlatformInfo()) >= IGFX_METEORLAKE) {
@@ -187,7 +187,8 @@ void SetWorkaroundTable(SKU_FEATURE_TABLE *pSkuFeatureTable, CPlatform *platform
187187
InitGt_20_04HwWaTable(&waTable, pSkuFeatureTable, &stWaInitParam);
188188
break;
189189
default:
190-
IGC_ASSERT(0);
190+
fprintf(stderr, "ERROR! Trying to select a workaround table for an unknown architecture. Aborting.\n");
191+
exit(1);
191192
break;
192193
}
193194
break;
@@ -205,7 +206,8 @@ void SetWorkaroundTable(SKU_FEATURE_TABLE *pSkuFeatureTable, CPlatform *platform
205206
InitGt_30_03HwWaTable(&waTable, pSkuFeatureTable, &stWaInitParam);
206207
break;
207208
default:
208-
IGC_ASSERT_MESSAGE(0, "unknown IP");
209+
fprintf(stderr, "ERROR! Trying to select a workaround table for an unknown architecture. Aborting.\n");
210+
exit(1);
209211
break;
210212
}
211213
stWaInitParam.usWaIpShift = WA_BIT_GT;

0 commit comments

Comments
 (0)