From: Gert Wollny Date: Mon, 26 Mar 2018 08:17:00 +0000 (-0600) Subject: mesa/st/tests: Use tgsi opcode enum also in the test classes X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=a21da49e5c55f8e61253503d865cef936125ea5f;p=mesa.git mesa/st/tests: Use tgsi opcode enum also in the test classes Fixes: ec478cf9c31K ("st/mesa,tgsi: use enum tgsi_opcode") Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105737 Signed-off-by: Gert Wollny Reviewed-by: Brian Paul --- diff --git a/src/mesa/state_tracker/tests/st_tests_common.cpp b/src/mesa/state_tracker/tests/st_tests_common.cpp index ea01ca5555f..63e3d6b2c41 100644 --- a/src/mesa/state_tracker/tests/st_tests_common.cpp +++ b/src/mesa/state_tracker/tests/st_tests_common.cpp @@ -43,7 +43,7 @@ using std::tuple; /* Implementation of helper and test classes */ void *FakeCodeline::mem_ctx = nullptr; -FakeCodeline::FakeCodeline(unsigned _op, const vector& _dst, +FakeCodeline::FakeCodeline(tgsi_opcode _op, const vector& _dst, const vector& _src, const vector&_to): op(_op), max_temp_id(0) @@ -59,7 +59,7 @@ FakeCodeline::FakeCodeline(unsigned _op, const vector& _dst, } -FakeCodeline::FakeCodeline(unsigned _op, const vector>& _dst, +FakeCodeline::FakeCodeline(tgsi_opcode _op, const vector>& _dst, const vector>& _src, const vector>&_to, SWZ with_swizzle): @@ -84,7 +84,7 @@ FakeCodeline::FakeCodeline(unsigned _op, const vector>& _dst, }); } -FakeCodeline::FakeCodeline(unsigned _op, const vector>& _dst, +FakeCodeline::FakeCodeline(tgsi_opcode _op, const vector>& _dst, const vector>& _src, const vector>&_to, RA with_reladdr): op(_op), diff --git a/src/mesa/state_tracker/tests/st_tests_common.h b/src/mesa/state_tracker/tests/st_tests_common.h index 2e188329231..6d855fe5811 100644 --- a/src/mesa/state_tracker/tests/st_tests_common.h +++ b/src/mesa/state_tracker/tests/st_tests_common.h @@ -40,15 +40,15 @@ struct RA {}; /* A line to describe a TGSI instruction for building mock shaders. */ struct FakeCodeline { - FakeCodeline(unsigned _op): op(_op), max_temp_id(0) {} - FakeCodeline(unsigned _op, const std::vector& _dst, const std::vector& _src, + FakeCodeline(tgsi_opcode _op): op(_op), max_temp_id(0) {} + FakeCodeline(tgsi_opcode _op, const std::vector& _dst, const std::vector& _src, const std::vector&_to); - FakeCodeline(unsigned _op, const std::vector>& _dst, + FakeCodeline(tgsi_opcode _op, const std::vector>& _dst, const std::vector>& _src, const std::vector>&_to, SWZ with_swizzle); - FakeCodeline(unsigned _op, const std::vector>& _dst, + FakeCodeline(tgsi_opcode _op, const std::vector>& _dst, const std::vector>& _src, const std::vector>&_to, RA with_reladdr); @@ -78,7 +78,7 @@ private: template void read_reg(const st_reg& s); - unsigned op; + tgsi_opcode op; std::vector dst; std::vector src; std::vector tex_offsets;