-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[binutils, ARM, 9/16] New BFL instruction for Armv8.1-M Mainline
This patch is part of a series of patches to add support for Armv8.1-M Mainline instructions to binutils. This patch adds the BFL instruction. *** gas/ChangeLog *** 2019-04-15 Sudakshina Das <[email protected]> Andre Vieira <[email protected]> * config/tc-arm.c (T16_32_TAB): New entrie for bfl. (do_t_v8_1_branch): New switch case for bfl. (insns): New instruction for bfl. * testsuite/gas/arm/armv8_1-m-bfl.d: New. * testsuite/gas/arm/armv8_1-m-bfl.s: New. * testsuite/gas/arm/armv8_1-m-bfl-bad.s: New. * testsuite/gas/arm/armv8_1-m-bfl-bad.d: New. * testsuite/gas/arm/armv8_1-m-bfl-bad.l: New. * testsuite/gas/arm/armv8_1-m-bfl-rel.d: New. * testsuite/gas/arm/armv8_1-m-bfl-rel.s: New. *** ld/ChangeLog *** 2019-04-15 Sudakshina Das <[email protected]> * testsuite/ld-arm/bfl.s: New. * testsuite/ld-arm/bfl.d: New. * testsuite/ld-arm/arm-elf.exp: Add above test. *** opcodes/ChangeLog *** 2019-04-15 Sudakshina Das <[email protected]> * arm-dis.c (thumb32_opcodes): New instruction bfl.
- Loading branch information
1 parent
1caf72a
commit 65d1bc0
Showing
15 changed files
with
150 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,17 @@ | ||
2019-04-15 Sudakshina Das <[email protected]> | ||
Andre Vieira <[email protected]> | ||
|
||
* config/tc-arm.c (T16_32_TAB): New entrie for bfl. | ||
(do_t_v8_1_branch): New switch case for bfl. | ||
(insns): New instruction for bfl. | ||
* testsuite/gas/arm/armv8_1-m-bfl.d: New. | ||
* testsuite/gas/arm/armv8_1-m-bfl.s: New. | ||
* testsuite/gas/arm/armv8_1-m-bfl-bad.s: New. | ||
* testsuite/gas/arm/armv8_1-m-bfl-bad.d: New. | ||
* testsuite/gas/arm/armv8_1-m-bfl-bad.l: New. | ||
* testsuite/gas/arm/armv8_1-m-bfl-rel.d: New. | ||
* testsuite/gas/arm/armv8_1-m-bfl-rel.s: New. | ||
|
||
2019-04-15 Sudakshina Das <[email protected]> | ||
|
||
* config/tc-arm.c (md_pcrel_from_section): New switch case for | ||
|
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,4 @@ | ||
#name: Invalid Armv8.1-M Mainline BFL instructions | ||
#source: armv8_1-m-bfl-bad.s | ||
#as: -march=armv8.1-m.main | ||
#error_output: armv8_1-m-bfl-bad.l |
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,9 @@ | ||
.*: Assembler messages: | ||
.*:6: Error: branch out of range or not a multiple of 2 | ||
.*:7: Error: branch out of range or not a multiple of 2 | ||
.*:8: Error: branch out of range or not a multiple of 2 | ||
.*:9: Error: branch out of range or not a multiple of 2 | ||
.*:11: Error: branch out of range or not a multiple of 2 | ||
.*:12: Error: branch out of range or not a multiple of 2 | ||
.*:13: Error: branch out of range or not a multiple of 2 | ||
.*:14: Error: branch out of range or not a multiple of 2 |
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,14 @@ | ||
.syntax unified | ||
.text | ||
.thumb | ||
foo: | ||
# OP0 : Unsigned, 5-bit, even | ||
bfl 0, 36 | ||
bfl -2, 36 | ||
bfl 3, 36 | ||
bfl 32, 36 | ||
# OP1 : signed, 19-bit, even | ||
bf 2, -5 | ||
bf 2, 5 | ||
bf 2, 262144 | ||
bf 2, -262146 |
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,10 @@ | ||
#name: Valid Armv8.1-M Mainline BFL instruction with relocation | ||
#as: -march=armv8.1-m.main | ||
#objdump: -dr --prefix-addresses --show-raw-insn | ||
#skip: *-*-pe *-wince-* | ||
|
||
.*: +file format .*arm.* | ||
|
||
Disassembly of section .text: | ||
0[0-9a-f]+ <[^>]+> f0ff c7ff bfl 2, 00000000 <.target> | ||
0: R_ARM_THM_BF18 .target |
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,5 @@ | ||
.syntax unified | ||
.text | ||
.thumb | ||
foo: | ||
bfl 2, .target |
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,13 @@ | ||
#name: Valid Armv8.1-M Mainline BFL instruction | ||
#as: -march=armv8.1-m.main | ||
#objdump: -dr --prefix-addresses --show-raw-insn | ||
|
||
.*: +file format .*arm.* | ||
|
||
Disassembly of section .text: | ||
0[0-9a-f]+ <[^>]+> f080 c803 bfl 2, 0000000a <foo\+0xa> | ||
0[0-9a-f]+ <[^>]+> 4608 mov r0, r1 | ||
0[0-9a-f]+ <[^>]+> f100 c801 bfl 4, 0000000c <foo\+0xc> | ||
0[0-9a-f]+ <[^>]+> 460a mov r2, r1 | ||
0[0-9a-f]+ <[^>]+> 4613 mov r3, r2 | ||
0[0-9a-f]+ <[^>]+> 4614 mov r4, r2 |
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,12 @@ | ||
.syntax unified | ||
.text | ||
.thumb | ||
foo: | ||
bfl 2, 6 | ||
mov r0, r1 | ||
bfl .LBranch, .LB2 | ||
mov r2, r1 | ||
.LB2: | ||
mov r3, r2 | ||
.LBranch: | ||
mov r4, r2 |
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 |
---|---|---|
@@ -1,3 +1,9 @@ | ||
2019-04-15 Sudakshina Das <[email protected]> | ||
|
||
* testsuite/ld-arm/bfl.s: New. | ||
* testsuite/ld-arm/bfl.d: New. | ||
* testsuite/ld-arm/arm-elf.exp: Add above test. | ||
|
||
2019-04-15 Sudakshina Das <[email protected]> | ||
|
||
* testsuite/ld-arm/bf.s: New. | ||
|
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,14 @@ | ||
|
||
.*: file format elf32-.*arm | ||
|
||
|
||
Disassembly of section .text: | ||
|
||
00001000 <_start>: | ||
1000: f0ff c7ff bfl 2, 1001000 <bar> | ||
1000: R_ARM_THM_BF18 bar | ||
|
||
Disassembly of section .foo: | ||
|
||
01001000 <bar>: | ||
1001000: 4770 bx lr |
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,19 @@ | ||
.global _start | ||
.syntax unified | ||
|
||
@ We will place the section .text at 0x1000. | ||
|
||
.text | ||
.thumb_func | ||
|
||
_start: | ||
bfl 2, bar | ||
|
||
@ We will place the section .foo at 0x1001000. | ||
|
||
.section .foo, "xa" | ||
.thumb_func | ||
|
||
bar: | ||
bx lr | ||
|
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 |
---|---|---|
@@ -1,3 +1,7 @@ | ||
2019-04-15 Sudakshina Das <[email protected]> | ||
|
||
* arm-dis.c (thumb32_opcodes): New instruction bfl. | ||
|
||
2019-04-15 Sudakshina Das <[email protected]> | ||
|
||
* arm-dis.c (print_insn_thumb32): Updated to accept new %Y pattern. | ||
|
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