-
Notifications
You must be signed in to change notification settings - Fork 10.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[RISCV] Support instruction sizes up to 176-bits in disassembler. (#9…
…0371) We don't have any instructions defined yet, but that we can still read the correct number of bytes when disassembling. This should better match GNU objdump behavior.
- Loading branch information
Showing
2 changed files
with
66 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# RUN: llvm-mc -filetype=obj -triple riscv32 < %s \ | ||
# RUN: | llvm-objdump -d - | FileCheck %s | ||
|
||
# CHECK: 011f 4523 8967 <unknown> | ||
.byte 0x1f, 0x01, 0x23, 0x45, 0x67, 0x89 | ||
|
||
# CHECK: 4523013f cdab8967 <unknown> | ||
.byte 0x3f, 0x01, 0x23, 0x45, 0x67, 0x89, 0xab, 0xcd | ||
|
||
# CHECK: 007f 4523 8967 cdab feef <unknown> | ||
.byte 0x7f, 0x00, 0x23, 0x45, 0x67, 0x89, 0xab, 0xcd, 0xef, 0xfe | ||
|
||
# CHECK: 4523107f cdab8967 badcfeef <unknown> | ||
.byte 0x7f, 0x10, 0x23, 0x45, 0x67, 0x89, 0xab, 0xcd, 0xef, 0xfe, 0xdc, 0xba | ||
|
||
# CHECK: 207f 4523 8967 cdab feef badc 7698 <unknown> | ||
.byte 0x7f, 0x20, 0x23, 0x45, 0x67, 0x89, 0xab, 0xcd, 0xef, 0xfe, 0xdc, 0xba, 0x98, 0x76 | ||
|
||
# CHECK: 4523307f cdab8967 badcfeef 32547698 <unknown> | ||
.byte 0x7f, 0x30, 0x23, 0x45, 0x67, 0x89, 0xab, 0xcd, 0xef, 0xfe, 0xdc, 0xba, 0x98, 0x76, 0x54, 0x32 | ||
|
||
# CHECK: 407f 4523 8967 cdab feef badc 7698 3254 1210 <unknown> | ||
.byte 0x7f, 0x40, 0x23, 0x45, 0x67, 0x89, 0xab, 0xcd, 0xef, 0xfe, 0xdc, 0xba, 0x98, 0x76, 0x54, 0x32, 0x10, 0x12 | ||
|
||
# CHECK: 4523507f cdab8967 badcfeef 32547698 56341210 <unknown> | ||
.byte 0x7f, 0x50, 0x23, 0x45, 0x67, 0x89, 0xab, 0xcd, 0xef, 0xfe, 0xdc, 0xba, 0x98, 0x76, 0x54, 0x32, 0x10, 0x12, 0x34, 0x56 | ||
|
||
# CHECK: 607f 4523 8967 cdab feef badc 7698 3254 1210 5634 9a78 <unknown> | ||
.byte 0x7f, 0x60, 0x23, 0x45, 0x67, 0x89, 0xab, 0xcd, 0xef, 0xfe, 0xdc, 0xba, 0x98, 0x76, 0x54, 0x32, 0x10, 0x12, 0x34, 0x56, 0x78, 0x9a |