summaryrefslogtreecommitdiffstats
path: root/test/MC/COFF/symbol-mangling.ll
diff options
context:
space:
mode:
Diffstat (limited to 'test/MC/COFF/symbol-mangling.ll')
-rw-r--r--test/MC/COFF/symbol-mangling.ll17
1 files changed, 17 insertions, 0 deletions
diff --git a/test/MC/COFF/symbol-mangling.ll b/test/MC/COFF/symbol-mangling.ll
new file mode 100644
index 0000000..f1b4b4b
--- /dev/null
+++ b/test/MC/COFF/symbol-mangling.ll
@@ -0,0 +1,17 @@
+; The purpose of this test is to see if the MC layer properly handles symbol
+; names needing quoting on MS/Windows. This code is generated by clang when
+; using -cxx-abi microsoft.
+
+; RUN: llc -filetype=asm -mtriple i686-pc-win32 %s -o - | FileCheck %s
+
+; CHECK: ?sayhi@A@@QBEXXZ
+
+%struct.A = type {}
+
+define i32 @main() {
+entry:
+ tail call void @"\01?sayhi@A@@QBEXXZ"(%struct.A* null)
+ ret i32 0
+}
+
+declare void @"\01?sayhi@A@@QBEXXZ"(%struct.A*)
OpenPOWER on IntegriCloud