2018-12-15 01:59:27 +08:00
|
|
|
; Run llvm-undname with invalid inputs and make sure it doesn't crash.
|
2019-04-16 21:18:51 +08:00
|
|
|
; RUN: not llvm-undname < %s 2>&1 | FileCheck %s
|
2018-12-15 01:59:27 +08:00
|
|
|
|
|
|
|
?ff@@$$J0YAXAU?$AS_@$0A@PEAU?$AS_@$0A@H@__clang@@@__clang@@@Z
|
|
|
|
; CHECK: ?ff@@$$J0YAXAU?$AS_@$0A@PEAU?$AS_@$0A@H@__clang@@@__clang@@@Z
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2018-12-15 02:10:13 +08:00
|
|
|
|
|
|
|
?f0@@YAXPEU?$AS_@$00$$CAD@__clang@@@Z
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?f0@@YAXPEU?$AS_@$00$$CAD@__clang@@@Z
|
2019-04-04 07:15:56 +08:00
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?@@8
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?@@8
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-04 07:19:39 +08:00
|
|
|
|
|
|
|
??
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-04 07:23:32 +08:00
|
|
|
|
|
|
|
??0@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??0@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-04 07:27:18 +08:00
|
|
|
|
|
|
|
? @@ YC@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ? @@ YC@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-09 03:46:53 +08:00
|
|
|
|
|
|
|
??B@$$J0
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??B@$$J0
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??B@4
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??B@4
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?A?@?@???B@4D
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?A?@?@???B@4D
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?A?@?@???B@4DD
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?A?@?@???B@4DD
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??$A@P15@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??$A@P15@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??$A@P
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??$A@P
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?A@@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?A@@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?A@@P
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?A@@P
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?A@@4PQA@@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?A@@4PQA@@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??__E
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??__E
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??__E@@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??__E@@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??__E?Foo@@0HA@@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??__E?Foo@@0HA@@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-11 01:31:34 +08:00
|
|
|
|
2019-06-05 02:06:28 +08:00
|
|
|
??__E?i@C@@0HA@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??__E?i@C@@0HA@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??__E?Foo@@YAXXZ
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??__E?Foo@@YAXXZ
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
2019-06-05 02:49:05 +08:00
|
|
|
?foo@@YAH0@Z
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@@YAH0@Z
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?foo@@YAHH
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@@YAHH
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
2019-04-11 01:31:34 +08:00
|
|
|
??8@8
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??8@8
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-12 06:23:35 +08:00
|
|
|
|
|
|
|
?B@?$?K$H?
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?B@?$?K$H?
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-12 06:47:18 +08:00
|
|
|
|
|
|
|
??C@$
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??C@$
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-12 06:59:25 +08:00
|
|
|
|
|
|
|
?x@@3PAW
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?x@@3PAW
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-12 07:11:33 +08:00
|
|
|
|
|
|
|
??}
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??}
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-15 07:08:12 +08:00
|
|
|
|
|
|
|
?foo@?$?_
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@?$?_
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-15 07:32:37 +08:00
|
|
|
|
|
|
|
??_R4
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_R4
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_R4foo@@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_R4foo@@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-16 00:42:44 +08:00
|
|
|
|
|
|
|
?foo@?$?BH@@QAEHXZ
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@?$?BH@@QAEHXZ
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-16 22:10:34 +08:00
|
|
|
|
|
|
|
?foo@?$?0H@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@?$?0H@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-19 03:30:21 +08:00
|
|
|
|
|
|
|
??_C@_0A@01234567@a
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_0A@01234567@a
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_C@_1A@01234567@a
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_1A@01234567@a
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-19 03:52:32 +08:00
|
|
|
|
|
|
|
??_C@_0301234567@a
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_0301234567@a
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_C@_1301234567@a
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_1301234567@a
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-21 22:25:07 +08:00
|
|
|
|
|
|
|
??_C@_0601234567@abcdefghijklmnopqrtsuvwxyzABCDEFGHIJKLMNOPQRTSUVWXYZabcdefghijklmnopqrtsuvwxyzABCDEFGHIJKLMNOPQRTSUVWXYZabcdefghijklmnopqrtsuvwxyz
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_0601234567@abcdefghijklmnopqrtsuvwxyzABCDEFGHIJKLMNOPQRTSUVWXYZabcdefghijklmnopqrtsuvwxyzABCDEFGHIJKLMNOPQRTSUVWXYZabcdefghijklmnopqrtsuvwxyz
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-04-22 23:05:18 +08:00
|
|
|
|
|
|
|
??_C@_12@?z
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_12@?z
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-05-22 23:53:23 +08:00
|
|
|
|
|
|
|
??$foo@$1??_C@_02PCEFGMJL@hi?$AA@@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??$foo@$1??_C@_02PCEFGMJL@hi?$AA@@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-06-03 07:48:28 +08:00
|
|
|
|
|
|
|
??_C@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_C@_
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_C@_3
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_3
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_C@_01
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_01
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_C@_0101234567@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_0101234567@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_C@_0101234567@?
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_0101234567@?
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_C@_0101234567@?$
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_0101234567@?$
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_C@_0101234567@?$za
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_0101234567@?$za
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_C@_0101234567@?$az
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_0101234567@?$az
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
2019-06-04 23:13:30 +08:00
|
|
|
??_C@_1201234567@a?$az
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_C@_1201234567@a?$az
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
2019-06-03 07:48:28 +08:00
|
|
|
??@foo
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??@foo
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-06-04 23:13:30 +08:00
|
|
|
|
|
|
|
?foo@@3YA@A
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@@3YA@A
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?foo@@3Y~01KA
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@@3Y~01KA
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?foo@@3Y0~1KA
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@@3Y0~1KA
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?x@@3PEAY02$$CRHEA
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?x@@3PEAY02$$CRHEA
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-06-04 23:38:00 +08:00
|
|
|
|
|
|
|
?foo@@3_
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@@3_
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?foo@@3_XA
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@@3_XA
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?foo@@3Vbar
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@@3Vbar
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?foo@@3Vbar@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@@3Vbar@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?foo@?A
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@?A
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-06-04 23:47:25 +08:00
|
|
|
|
|
|
|
?foo@?
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@?
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?foo@??
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@??
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?foo@?XX?
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@?XX?
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?foo@?A@?
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@?A@?
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?foo@?Q@?
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@?Q@?
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?foo@?BQ@?
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@?BQ@?
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
?foo@?0?
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ?foo@?0?
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
2019-06-05 00:25:28 +08:00
|
|
|
|
|
|
|
??_Sfoo@@1Abar@@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_Sfoo@@1Abar@@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_Bfoo@@1
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_Bfoo@@1
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_R0
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_R0
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_R0H
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_R0H
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_R0H@8foo
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_R0H@8foo
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_R1012?3foo@@
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_R1012?3foo@@
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_R2foo@@1
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_R2foo@@1
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_A
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_A
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|
|
|
|
|
|
|
|
??_P
|
|
|
|
; CHECK-EMPTY:
|
|
|
|
; CHECK-NEXT: ??_P
|
|
|
|
; CHECK-NEXT: error: Invalid mangled name
|