]> git.baikalelectronics.ru Git - kernel.git/commit
perf/tests: Add misc instructions to the x86 instruction decoder test
authorAdrian Hunter <adrian.hunter@intel.com>
Thu, 2 Dec 2021 09:50:26 +0000 (11:50 +0200)
committerBorislav Petkov <bp@suse.de>
Sun, 23 Jan 2022 19:37:50 +0000 (20:37 +0100)
commit52bf50f03d845829715c47705d054de153aac569
tree2ba79b0d8feef4115f56ea1f890edc3d144d98f7
parent92ee8b4eca0299d11e6fc95c6884e8c08fc08a9b
perf/tests: Add misc instructions to the x86 instruction decoder test

The x86 instruction decoder is used for both kernel instructions and
user space instructions (e.g. uprobes, perf tools Intel PT), so it is
good to update it with new instructions.

Add the following instructions to the x86 instruction decoder test:

User Interrupt

clui
senduipi
stui
testui
uiret

Prediction history reset

hreset

Serialize instruction execution

serialize

TSX suspend load address tracking

xresldtrk
xsusldtrk

A subsequent patch adds the instructions to the instruction decoder.

Reference:
Intel Architecture Instruction Set Extensions and Future Features
Programming Reference
May 2021
Document Number: 319433-044

Example:

  $ perf test -v "x86 instruction decoder" |& grep -i hreset
  Failed to decode length (4 vs expected 6): f3 0f 3a f0 c0 00     hreset $0x0
  Failed to decode length (4 vs expected 6): f3 0f 3a f0 c0 00     hreset $0x0

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Borislav Petkov <bp@suse.de>
Acked-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Acked-by: Masami Hiramatsu <mhiramat@kernel.org>
Link: https://lore.kernel.org/r/20211202095029.2165714-4-adrian.hunter@intel.com
tools/perf/arch/x86/tests/insn-x86-dat-32.c
tools/perf/arch/x86/tests/insn-x86-dat-64.c
tools/perf/arch/x86/tests/insn-x86-dat-src.c