From cac416fd956a7349250bc624faf5a7c4ce5c07a8 Mon Sep 17 00:00:00 2001 From: Dmitry Selyutin Date: Sun, 4 Sep 2022 15:10:56 +0300 Subject: [PATCH] power_insn: try exact name matching first --- src/openpower/decoder/power_insn.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/openpower/decoder/power_insn.py b/src/openpower/decoder/power_insn.py index 34ae8895..3a3a6625 100644 --- a/src/openpower/decoder/power_insn.py +++ b/src/openpower/decoder/power_insn.py @@ -1380,8 +1380,11 @@ class PPCDatabase: for (section, records) in self.__db.items(): for record in records: - if (exact_match(key, record) or - Rc_match(key, record) or + if exact_match(key, record): + return (section, record) + + for record in records: + if (Rc_match(key, record) or LK_match(key, record) or AA_match(key, record)): return (section, record) -- 2.30.2