aboutsummaryrefslogtreecommitdiffstats
path: root/test/MC/MachO
diff options
context:
space:
mode:
authorChad Rosier <mcrosier@apple.com>2013-02-12 18:29:02 +0000
committerChad Rosier <mcrosier@apple.com>2013-02-12 18:29:02 +0000
commit8915e27704b2afd362a69c6be1111fb06bbcc727 (patch)
tree068e87c713405ef644808ce4b7e7bb49eea6c289 /test/MC/MachO
parent1cb058f77c7b15045c677ef30586fe45c2929010 (diff)
downloadexternal_llvm-8915e27704b2afd362a69c6be1111fb06bbcc727.zip
external_llvm-8915e27704b2afd362a69c6be1111fb06bbcc727.tar.gz
external_llvm-8915e27704b2afd362a69c6be1111fb06bbcc727.tar.bz2
[ms-inline asm] Add support for lexing binary integers with a [bB] suffix.
This is complicated by backward labels (e.g., 0b can be both a backward label and a binary zero). The current implementation assumes [0-9]b is always a label and thus it's possible for 0b and 1b to not be interpreted correctly for ms-style inline assembly. However, this is relatively simple to fix in the inline assembly (i.e., drop the [bB]). This patch also limits backward labels to [0-9]b, so that only 0b and 1b are ambiguous. Part of rdar://12470373 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174983 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/MC/MachO')
-rw-r--r--test/MC/MachO/direction_labels.s12
1 files changed, 6 insertions, 6 deletions
diff --git a/test/MC/MachO/direction_labels.s b/test/MC/MachO/direction_labels.s
index e224ed3..35f5d44 100644
--- a/test/MC/MachO/direction_labels.s
+++ b/test/MC/MachO/direction_labels.s
@@ -1,15 +1,15 @@
// RUN: llvm-mc -triple i386-apple-darwin9 %s -filetype=obj -o - | macho-dump --dump-section-data | FileCheck %s
direction_labels:
-10: nop
- jmp 10b
- nop
+8: nop
+ jmp 8b
+ nop
jne 0f
0: nop
jne 0b
- jmp 11f
-11: nop
- ret
+ jmp 9f
+9: nop
+ ret
// CHECK: ('cputype', 7)
// CHECK: ('cpusubtype', 3)