intel/compiler/test: fix crashes when TEST_DEBUG is set
Dumping instructions requires that ISA info is not empty. Reviewed-by: José Roberto de Souza <jose.souza@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24274>
This commit is contained in:

committed by
Marge Bot

parent
23a2b83639
commit
4f1125e4ae
@@ -47,7 +47,11 @@ void scoreboard_test::SetUp()
|
|||||||
ctx = ralloc_context(NULL);
|
ctx = ralloc_context(NULL);
|
||||||
compiler = rzalloc(ctx, struct brw_compiler);
|
compiler = rzalloc(ctx, struct brw_compiler);
|
||||||
devinfo = rzalloc(ctx, struct intel_device_info);
|
devinfo = rzalloc(ctx, struct intel_device_info);
|
||||||
|
devinfo->ver = 12;
|
||||||
|
devinfo->verx10 = devinfo->ver * 10;
|
||||||
|
|
||||||
compiler->devinfo = devinfo;
|
compiler->devinfo = devinfo;
|
||||||
|
brw_init_isa_info(&compiler->isa, devinfo);
|
||||||
|
|
||||||
params = {};
|
params = {};
|
||||||
params.mem_ctx = ctx;
|
params.mem_ctx = ctx;
|
||||||
@@ -59,8 +63,6 @@ void scoreboard_test::SetUp()
|
|||||||
v = new fs_visitor(compiler, ¶ms, NULL, &prog_data->base, shader, 8,
|
v = new fs_visitor(compiler, ¶ms, NULL, &prog_data->base, shader, 8,
|
||||||
false, false);
|
false, false);
|
||||||
|
|
||||||
devinfo->ver = 12;
|
|
||||||
devinfo->verx10 = devinfo->ver * 10;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void scoreboard_test::TearDown()
|
void scoreboard_test::TearDown()
|
||||||
@@ -885,6 +887,7 @@ TEST_F(scoreboard_test, conditional8)
|
|||||||
TEST_F(scoreboard_test, gfx125_RaR_over_different_pipes)
|
TEST_F(scoreboard_test, gfx125_RaR_over_different_pipes)
|
||||||
{
|
{
|
||||||
devinfo->verx10 = 125;
|
devinfo->verx10 = 125;
|
||||||
|
brw_init_isa_info(&compiler->isa, devinfo);
|
||||||
|
|
||||||
const fs_builder &bld = v->bld;
|
const fs_builder &bld = v->bld;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user