1 /*
2 * This file and its contents are supplied under the terms of the
3 * Common Development and Distribution License ("CDDL"), version 1.0.
4 * You may only use this file in accordance with the terms of version
5 * 1.0 of the CDDL.
6 *
7 * A full copy of the text of the CDDL should have accompanied this
8 * source. A copy of the CDDL is also available via the Internet at
9 * http://www.illumos.org/license/CDDL.
10 */
11
12 /*
13 * Copyright 2017 Jason King
14 */
15 #include <sysdemangle.h>
16 #include <sys/debug.h>
17 #include <sys/types.h>
18 #include <string.h>
19 #include <stdlib.h>
20
21 /*
22 * Symbol names were generated using the following:
23 * nm libstdc++.so | awk -F\| '{ print $8 }' | grep '^_Z'
24 * and then fed into c++filt on an OS X system to generate the
25 * demangled names.
26 */
27
28 static struct {
29 const char *mangled;
30 const char *demangled;
31 } tests[] = {
32 /* BEGIN CSTYLED */
33 { "_ZGVN9__gnu_cxx16bitmap_allocatorIcE13_S_mem_blocksE",
34 "guard variable for __gnu_cxx::bitmap_allocator<char>::_S_mem_blocks" },
35 { "_ZGVN9__gnu_cxx16bitmap_allocatorIcE15_S_last_requestE",
36 "guard variable for __gnu_cxx::bitmap_allocator<char>::_S_last_request" },
37 { "_ZGVN9__gnu_cxx16bitmap_allocatorIcE6_S_mutE",
38 "guard variable for __gnu_cxx::bitmap_allocator<char>::_S_mut" },
39 { "_ZGVN9__gnu_cxx16bitmap_allocatorIwE13_S_mem_blocksE",
|
1 /*
2 * This file and its contents are supplied under the terms of the
3 * Common Development and Distribution License ("CDDL"), version 1.0.
4 * You may only use this file in accordance with the terms of version
5 * 1.0 of the CDDL.
6 *
7 * A full copy of the text of the CDDL should have accompanied this
8 * source. A copy of the CDDL is also available via the Internet at
9 * http://www.illumos.org/license/CDDL.
10 */
11
12 /*
13 * Copyright 2017 Jason King
14 */
15 #include <sys/debug.h>
16 #include <sys/types.h>
17 #include <string.h>
18 #include <stdlib.h>
19 #include <demangle-sys.h>
20
21 /*
22 * Symbol names were generated using the following:
23 * nm libstdc++.so | awk -F\| '{ print $8 }' | grep '^_Z'
24 * and then fed into c++filt on an OS X system to generate the
25 * demangled names.
26 */
27
28 static struct {
29 const char *mangled;
30 const char *demangled;
31 } tests[] = {
32 /* BEGIN CSTYLED */
33 { "_ZGVN9__gnu_cxx16bitmap_allocatorIcE13_S_mem_blocksE",
34 "guard variable for __gnu_cxx::bitmap_allocator<char>::_S_mem_blocks" },
35 { "_ZGVN9__gnu_cxx16bitmap_allocatorIcE15_S_last_requestE",
36 "guard variable for __gnu_cxx::bitmap_allocator<char>::_S_last_request" },
37 { "_ZGVN9__gnu_cxx16bitmap_allocatorIcE6_S_mutE",
38 "guard variable for __gnu_cxx::bitmap_allocator<char>::_S_mut" },
39 { "_ZGVN9__gnu_cxx16bitmap_allocatorIwE13_S_mem_blocksE",
|