[LLDB][LoongArch] Add unittests for EmulateInstructionLoongArch
authorHui Li <lihui@loongson.cn>
Fri, 13 Jan 2023 02:17:48 +0000 (10:17 +0800)
committerWeining Lu <luweining@loongson.cn>
Fri, 13 Jan 2023 02:17:55 +0000 (10:17 +0800)
commit1eaadaea5090f88d4e26331a5046a1a07f15a6ea
tree540502b7502da80d6d7ebfd4eaa499096058a742
parentd52582b6b7dfff5538008ad1ebb141da283d9206
[LLDB][LoongArch] Add unittests for EmulateInstructionLoongArch

Add unit tests For EmulateInstructionLoongArch existing branch instruction.
Add 19 test cases in total.

Without this patch:

```
$ ninja check-lldb-unit
[0/1] Running lldb unit test suite

Testing Time: 10.55s
  Passed: 1025
```

With this patch:

```
$ ninja check-lldb-unit
[0/1] Running lldb unit test suite

Testing Time: 10.45s
  Passed: 1044
```

Reviewed By: DavidSpickett

Differential Revision: https://reviews.llvm.org/D140386
lldb/source/Plugins/Instruction/LoongArch/EmulateInstructionLoongArch.cpp
lldb/source/Plugins/Instruction/LoongArch/EmulateInstructionLoongArch.h
lldb/unittests/Instruction/CMakeLists.txt
lldb/unittests/Instruction/LoongArch/TestLoongArchEmulator.cpp [new file with mode: 0644]