aboutsummaryrefslogtreecommitdiffstats
path: root/test/MC/ELF/size.s
diff options
context:
space:
mode:
Diffstat (limited to 'test/MC/ELF/size.s')
-rw-r--r--test/MC/ELF/size.s15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/MC/ELF/size.s b/test/MC/ELF/size.s
new file mode 100644
index 0000000..7bbf661
--- /dev/null
+++ b/test/MC/ELF/size.s
@@ -0,0 +1,15 @@
+// RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux < %s | llvm-readobj -t | FileCheck %s
+
+foo:
+bar = .
+ .size foo, . - bar + 42
+
+// CHECK: Symbol {
+// CHECK: Name: foo
+// CHECK-NEXT: Value: 0x0
+// CHECK-NEXT: Size: 42
+// CHECK-NEXT: Binding: Local
+// CHECK-NEXT: Type: None
+// CHECK-NEXT: Other: 0
+// CHECK-NEXT: Section: .text
+// CHECK-NEXT: }