From 18f33b4a6809997a4d73824c5fdb4dd7c70e626a Mon Sep 17 00:00:00 2001 From: Eyck Jentzsch Date: Sun, 19 Jun 2022 16:52:29 +0200 Subject: [PATCH] fixes ordering of instructions for decoding --- gen_input/templates/CORENAME_decoder.cpp.gtl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gen_input/templates/CORENAME_decoder.cpp.gtl b/gen_input/templates/CORENAME_decoder.cpp.gtl index d6b7032..9291118 100644 --- a/gen_input/templates/CORENAME_decoder.cpp.gtl +++ b/gen_input/templates/CORENAME_decoder.cpp.gtl @@ -63,7 +63,7 @@ struct instruction_decoder<${coreDef.name.toLowerCase()}> { } for(auto& lut: qlut){ std::sort(std::begin(lut), std::end(lut), [](instruction_pattern const& a, instruction_pattern const& b){ - return bit_count(a.mask) > bit_count(b.mask); + return bit_count(a.mask) < bit_count(b.mask); }); } }