repo
stringlengths
1
152
file
stringlengths
14
221
code
stringlengths
501
25k
file_length
int64
501
25k
avg_line_length
float64
20
99.5
max_line_length
int64
21
134
extension_type
stringclasses
2 values
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/libart/art.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2019, Intel Corporation */ /* * Copyright 2016, FUJITSU TECHNOLOGY SOLUTIONS GMBH * Copyright 2012, Armon Dadgar. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the followi...
5,998
26.773148
78
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/libart/arttree_search.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2017, Intel Corporation */ /* * Copyright 2016, FUJITSU TECHNOLOGY SOLUTIONS GMBH * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * * Redistribut...
11,265
22.717895
80
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/libart/arttree.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2017, Intel Corporation */ /* * Copyright 2016, FUJITSU TECHNOLOGY SOLUTIONS GMBH * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * * Redistributions ...
2,337
34.969231
78
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/linkedlist/pmemobj_list.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016, Intel Corporation */ /* * pmemobj_list.h -- macro definitions for persistent * singly linked list and tail queue */ #ifndef PMEMOBJ_LISTS_H #define PMEMOBJ_LISTS_H #include <libpmemobj.h> /* * This file defines two types of persistent data structures: ...
11,243
30.762712
66
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/linkedlist/fifo.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016, Intel Corporation */ /* * fifo.c - example of tail queue usage */ #include <ex_common.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include "pmemobj_list.h" POBJ_LAYOUT_BEGIN(list); POBJ_LAYOUT_ROOT(list, struct fifo_root); POBJ_LAYOUT_TO...
2,782
21.264
64
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/map/map_hashmap_tx.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2017, Intel Corporation */ /* * map_hashmap_tx.c -- common interface for maps */ #include <map.h> #include <hashmap_tx.h> #include "map_hashmap_tx.h" /* * map_hm_tx_check -- wrapper for hm_tx_check */ static int map_hm_tx_check(PMEMobjpool *pop, TOID(str...
3,316
20.966887
70
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/map/kv_server.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2018, Intel Corporation */ /* * kv_server.c -- persistent tcp key-value store server */ #include <uv.h> #include <assert.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <unistd.h> #include "libpmemobj.h" #include "map.h" #include "m...
10,374
20.524896
79
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/map/map.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2018, Intel Corporation */ /* * map.h -- common interface for maps */ #ifndef MAP_H #define MAP_H #include <libpmemobj.h> #ifdef __cplusplus extern "C" { #endif #ifndef MAP_TYPE_OFFSET #define MAP_TYPE_OFFSET 1000 #endif TOID_DECLARE(struct map, MAP_TYP...
3,010
31.728261
78
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/map/data_store.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2018, Intel Corporation */ /* * data_store.c -- tree_map example usage */ #include <ex_common.h> #include <stdio.h> #include <sys/stat.h> #include <stdlib.h> #include <string.h> #include <time.h> #include <assert.h> #include "map.h" #include "map_ctree.h" #...
11,362
23.38412
117
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/map/map_rtree.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016, Intel Corporation */ /* * map_rtree.c -- common interface for maps */ #include <rtree_map.h> #include "map_rtree.h" /* * map_rtree_check -- wrapper for rtree_map_check */ static int map_rtree_check(PMEMobjpool *pop, TOID(struct map) map) { TOID(struct...
4,700
21.710145
75
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/map/map_hashmap_rp.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2018, Intel Corporation */ /* * map_hashmap_rp.c -- common interface for maps */ #include <map.h> #include <hashmap_rp.h> #include "map_hashmap_rp.h" /* * map_hm_rp_check -- wrapper for hm_rp_check */ static int map_hm_rp_check(PMEMobjpool *pop, TOID(struct ...
3,315
20.532468
70
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/map/hashmap_tx.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2019, Intel Corporation */ /* integer hash set implementation which uses only transaction APIs */ #include <stdlib.h> #include <stdio.h> #include <errno.h> #include <inttypes.h> #include <libpmemobj.h> #include "hashmap_tx.h" #include "hashmap_internal.h" /...
9,692
22.078571
80
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/map/map_skiplist.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016, Intel Corporation */ /* * map_skiplist.c -- common interface for maps */ #include <map.h> #include <skiplist_map.h> #include "map_skiplist.h" /* * map_skiplist_check -- wrapper for skiplist_map_check */ static int map_skiplist_check(PMEMobjpool *pop, T...
4,488
23.664835
78
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/map/map_ctree.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2017, Intel Corporation */ /* * map_ctree.c -- common interface for maps */ #include <map.h> #include <ctree_map.h> #include "map_ctree.h" /* * map_ctree_check -- wrapper for ctree_map_check */ static int map_ctree_check(PMEMobjpool *pop, TOID(struct ma...
4,091
21.483516
75
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/map/map_btree.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2017, Intel Corporation */ /* * map_btree.c -- common interface for maps */ #include <map.h> #include <btree_map.h> #include "map_btree.h" /* * map_btree_check -- wrapper for btree_map_check */ static int map_btree_check(PMEMobjpool *pop, TOID(struct ma...
4,091
21.483516
75
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/map/map_hashmap_atomic.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2017, Intel Corporation */ /* * map_hashmap_atomic.c -- common interface for maps */ #include <map.h> #include <hashmap_atomic.h> #include "map_hashmap_atomic.h" /* * map_hm_atomic_check -- wrapper for hm_atomic_check */ static int map_hm_atomic_check(P...
3,693
22.987013
74
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/map/map_rbtree.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2017, Intel Corporation */ /* * map_rbtree.c -- common interface for maps */ #include <map.h> #include <rbtree_map.h> #include "map_rbtree.h" /* * map_rbtree_check -- wrapper for rbtree_map_check */ static int map_rbtree_check(PMEMobjpool *pop, TOID(str...
4,199
22.076923
76
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/tree_map/ctree_map.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2019, Intel Corporation */ /* * ctree_map.c -- Crit-bit trie implementation */ #include <ex_common.h> #include <assert.h> #include <errno.h> #include <stdlib.h> #include <stdio.h> #include "ctree_map.h" #define BIT_IS_SET(n, i) (!!((n) & (1ULL << (i)))) #...
10,423
22.011038
83
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/tree_map/ctree_map.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2017, Intel Corporation */ /* * ctree_map.h -- TreeMap sorted collection implementation */ #ifndef CTREE_MAP_H #define CTREE_MAP_H #include <libpmemobj.h> #ifndef CTREE_MAP_TYPE_OFFSET #define CTREE_MAP_TYPE_OFFSET 1008 #endif struct ctree_map; TOID_DECL...
1,523
34.44186
79
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/tree_map/rtree_map.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2019, Intel Corporation */ /* * rtree_map.c -- implementation of rtree */ #include <ex_common.h> #include <assert.h> #include <errno.h> #include <limits.h> #include <stdlib.h> #include <stdbool.h> #include <stdio.h> #include "rtree_map.h" #include <x86intri...
14,705
21.081081
83
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/tree_map/btree_map.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2019, Intel Corporation */ /* * btree_map.c -- textbook implementation of btree /w preemptive splitting */ #include <assert.h> #include <errno.h> #include <stdio.h> #include "btree_map.h" #ifdef GET_NDP_PERFORMENCE #include <x86intrin.h> static inline u...
19,016
25.158184
83
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/tree_map/rtree_map.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016, Intel Corporation */ /* * rtree_map.h -- Radix TreeMap collection implementation */ #ifndef RTREE_MAP_H #define RTREE_MAP_H #include <libpmemobj.h> #ifndef RTREE_MAP_TYPE_OFFSET #define RTREE_MAP_TYPE_OFFSET 1020 #endif struct rtree_map; TOID_DECLARE(st...
1,739
36.826087
79
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/tree_map/rbtree_map.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2017, Intel Corporation */ /* * rbtree_map.h -- TreeMap sorted collection implementation */ #ifndef RBTREE_MAP_H #define RBTREE_MAP_H #include <libpmemobj.h> #ifndef RBTREE_MAP_TYPE_OFFSET #define RBTREE_MAP_TYPE_OFFSET 1016 #endif struct rbtree_map; TOI...
1,557
34.409091
73
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/tree_map/btree_map.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2017, Intel Corporation */ /* * btree_map.h -- TreeMap sorted collection implementation */ #ifndef BTREE_MAP_H #define BTREE_MAP_H #include <libpmemobj.h> #ifndef BTREE_MAP_TYPE_OFFSET #define BTREE_MAP_TYPE_OFFSET 1012 #endif struct btree_map; TOID_DECL...
1,523
34.44186
79
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmemobj/tree_map/rbtree_map.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2019, Intel Corporation */ /* * rbtree.c -- red-black tree implementation /w sentinel nodes */ #include <assert.h> #include <errno.h> #include "rbtree_map.h" #include <stdio.h> #include <x86intrin.h> static inline uint64_t getCycle(){ uint32_t cycles_hig...
14,171
23.102041
83
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/examples/libpmempool/manpage.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016, Intel Corporation */ /* * manpage.c -- simple example for the libpmempool man page */ #include <stddef.h> #include <unistd.h> #include <stdlib.h> #include <stdio.h> #include <libpmempool.h> #define PATH "./pmem-fs/myfile" #define CHECK_FLAGS (PMEMPOOL_CHE...
1,555
21.882353
70
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/librpmem/rpmem_ssh.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2018, Intel Corporation */ /* * rpmem_ssh.h -- rpmem ssh transport layer header file */ #ifndef RPMEM_SSH_H #define RPMEM_SSH_H 1 #include <stddef.h> #ifdef __cplusplus extern "C" { #endif struct rpmem_ssh; struct rpmem_ssh *rpmem_ssh_open(const struct r...
866
23.771429
76
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/librpmem/rpmem_fip.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2019, Intel Corporation */ /* * rpmem_fip.h -- rpmem libfabric provider module header file */ #ifndef RPMEM_FIP_H #define RPMEM_FIP_H #include <stdint.h> #include <netinet/in.h> #include <sys/types.h> #include <sys/socket.h> #ifdef __cplusplus extern "C" ...
1,427
22.032258
71
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/librpmem/rpmem.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2020, Intel Corporation */ /* * rpmem.c -- main source file for librpmem */ #include <stdlib.h> #include <netdb.h> #include <stdio.h> #include <errno.h> #include <limits.h> #include <inttypes.h> #include "librpmem.h" #include "out.h" #include "os.h" #includ...
20,542
21.451366
79
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/librpmem/rpmem_util.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2019, Intel Corporation */ /* * rpmem_util.h -- util functions for librpmem header file */ #ifndef RPMEM_UTIL_H #define RPMEM_UTIL_H 1 #ifdef __cplusplus extern "C" { #endif enum { LERR = 1, LWARN = 2, LNOTICE = 3, LINFO = 4, _LDBG = 10, }; #define ...
1,137
22.708333
71
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/librpmem/rpmem_obc.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2018, Intel Corporation */ /* * rpmem_obc.h -- rpmem out-of-band connection client header file */ #ifndef RPMEM_OBC_H #define RPMEM_OBC_H 1 #include <sys/types.h> #include <sys/socket.h> #include "librpmem.h" #ifdef __cplusplus extern "C" { #endif struc...
1,100
21.9375
65
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/librpmem/rpmem_obc.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2019, Intel Corporation */ /* * rpmem_obc.c -- rpmem out-of-band connection client source file */ #include <stdlib.h> #include <netdb.h> #include <errno.h> #include <string.h> #include <unistd.h> #include <sys/types.h> #include <sys/socket.h> #include "lib...
15,410
21.730088
80
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemblk/blk.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2014-2019, Intel Corporation */ /* * blk.h -- internal definitions for libpmem blk module */ #ifndef BLK_H #define BLK_H 1 #include <stddef.h> #include "ctl.h" #include "os_thread.h" #include "pool_hdr.h" #include "page_size.h" #ifdef __cplusplus extern "C" {...
2,483
23.116505
74
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemblk/libpmemblk.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2014-2018, Intel Corporation */ /* * libpmemblk.c -- pmem entry points for libpmemblk */ #include <stdio.h> #include <stdint.h> #include "libpmemblk.h" #include "ctl_global.h" #include "pmemcommon.h" #include "blk.h" /* * The variable from which the config i...
4,318
20.487562
78
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemblk/btt.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2014-2018, Intel Corporation */ /* * btt.h -- btt module definitions */ #ifndef BTT_H #define BTT_H 1 #ifdef __cplusplus extern "C" { #endif /* callback functions passed to btt_init() */ struct ns_callback { int (*nsread)(void *ns, unsigned lane, void *buf,...
1,908
30.816667
79
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemblk/btt_layout.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2014-2018, Intel Corporation */ /* * btt_layout.h -- block translation table on-media layout definitions */ /* * Layout of BTT info block. All integers are stored little-endian. */ #ifndef BTT_LAYOUT_H #define BTT_LAYOUT_H 1 #ifdef __cplusplus extern "C" { ...
3,197
28.611111
77
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemblk/blk.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2014-2020, Intel Corporation */ /* * blk.c -- block memory pool entry points for libpmem */ #include <inttypes.h> #include <stdio.h> #include <string.h> #include <sys/types.h> #include <sys/param.h> #include <unistd.h> #include <errno.h> #include <time.h> #inclu...
20,218
20.305585
77
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/container_ravl.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2018-2019, Intel Corporation */ /* * container_ravl.c -- implementation of ravl-based block container */ #include "container_ravl.h" #include "ravl.h" #include "out.h" #include "sys_util.h" struct block_container_ravl { struct block_container super; struct ra...
4,333
21.931217
79
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/heap_layout.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2018, Intel Corporation */ /* * heap_layout.h -- internal definitions for heap layout */ #ifndef LIBPMEMOBJ_HEAP_LAYOUT_H #define LIBPMEMOBJ_HEAP_LAYOUT_H 1 #include <stddef.h> #include <stdint.h> #ifdef __cplusplus extern "C" { #endif #define HEAP_MAJOR...
5,105
23.666667
78
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/alloc_class.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2020, Intel Corporation */ /* * alloc_class.h -- internal definitions for allocation classes */ #ifndef LIBPMEMOBJ_ALLOC_CLASS_H #define LIBPMEMOBJ_ALLOC_CLASS_H 1 #include <stddef.h> #include <stdint.h> #include <sys/types.h> #include "heap_layout.h" #inc...
1,815
21.7
71
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/recycler.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2019, Intel Corporation */ /* * recycler.c -- implementation of run recycler */ #include "heap.h" #include "recycler.h" #include "vec.h" #include "out.h" #include "util.h" #include "sys_util.h" #include "ravl.h" #include "valgrind_internal.h" #define THRES...
6,997
22.019737
79
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/alloc_class.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2020, Intel Corporation */ /* * alloc_class.c -- implementation of allocation classes */ #include <float.h> #include <string.h> #include "alloc_class.h" #include "heap_layout.h" #include "util.h" #include "out.h" #include "bucket.h" #include "critnib.h" #...
16,240
24.496075
80
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/obj.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2014-2020, Intel Corporation */ /* * obj.h -- internal definitions for obj module */ #ifndef LIBPMEMOBJ_OBJ_H #define LIBPMEMOBJ_OBJ_H 1 #include <stddef.h> #include <stdint.h> #include "lane.h" #include "pool_hdr.h" #include "pmalloc.h" #include "ctl.h" #incl...
8,196
25.441935
80
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/list.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2018, Intel Corporation */ /* * list.h -- internal definitions for persistent atomic lists module */ #ifndef LIBPMEMOBJ_LIST_H #define LIBPMEMOBJ_LIST_H 1 #include <stddef.h> #include <stdint.h> #include <sys/types.h> #include "libpmemobj.h" #include "lan...
1,376
20.184615
73
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/memops.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2020, Intel Corporation */ /* * memops.c -- aggregated memory operations helper implementation * * The operation collects all of the required memory modifications that * need to happen in an atomic way (all of them or none), and abstracts * away the stora...
24,116
25.589857
113
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/stats.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2017-2019, Intel Corporation */ /* * stats.c -- implementation of statistics */ #include "obj.h" #include "stats.h" STATS_CTL_HANDLER(persistent, curr_allocated, heap_curr_allocated); STATS_CTL_HANDLER(transient, run_allocated, heap_run_allocated); STATS_CTL_H...
3,293
20.671053
77
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/heap.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2019, Intel Corporation */ /* * heap.h -- internal definitions for heap */ #ifndef LIBPMEMOBJ_HEAP_H #define LIBPMEMOBJ_HEAP_H 1 #include <stddef.h> #include <stdint.h> #include "bucket.h" #include "memblock.h" #include "memops.h" #include "palloc.h" #inc...
3,719
26.969925
78
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/list.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2019, Intel Corporation */ /* * list.c -- implementation of persistent atomic lists module */ #include <inttypes.h> #include "list.h" #include "obj.h" #include "os_thread.h" #include "out.h" #include "sync.h" #include "valgrind_internal.h" #include "memops....
24,297
24.848936
80
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/memops.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2019, Intel Corporation */ /* * memops.h -- aggregated memory operations helper definitions */ #ifndef LIBPMEMOBJ_MEMOPS_H #define LIBPMEMOBJ_MEMOPS_H 1 #include <stddef.h> #include <stdint.h> #include "vec.h" #include "pmemops.h" #include "ulog.h" #inclu...
2,467
26.422222
74
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/pmalloc.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2018, Intel Corporation */ /* * pmalloc.h -- internal definitions for persistent malloc */ #ifndef LIBPMEMOBJ_PMALLOC_H #define LIBPMEMOBJ_PMALLOC_H 1 #include <stddef.h> #include <stdint.h> #include "libpmemobj.h" #include "memops.h" #include "palloc.h" ...
1,291
24.333333
76
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/recycler.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2019, Intel Corporation */ /* * recycler.h -- internal definitions of run recycler * * This is a container that stores runs that are currently not used by any of * the buckets. */ #ifndef LIBPMEMOBJ_RECYCLER_H #define LIBPMEMOBJ_RECYCLER_H 1 #include "m...
1,158
20.867925
77
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/palloc.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2019, Intel Corporation */ /* * palloc.h -- internal definitions for persistent allocator */ #ifndef LIBPMEMOBJ_PALLOC_H #define LIBPMEMOBJ_PALLOC_H 1 #include <stddef.h> #include <stdint.h> #include "libpmemobj.h" #include "memops.h" #include "ulog.h" #i...
3,006
25.377193
80
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/container.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2019, Intel Corporation */ /* * container.h -- internal definitions for block containers */ #ifndef LIBPMEMOBJ_CONTAINER_H #define LIBPMEMOBJ_CONTAINER_H 1 #include "memblock.h" #ifdef __cplusplus extern "C" { #endif struct block_container { const struc...
1,125
21.979592
72
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/stats.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2017-2019, Intel Corporation */ /* * stats.h -- definitions of statistics */ #ifndef LIBPMEMOBJ_STATS_H #define LIBPMEMOBJ_STATS_H 1 #include "ctl.h" #include "libpmemobj/ctl.h" #ifdef __cplusplus extern "C" { #endif struct stats_transient { uint64_t heap_ru...
2,990
26.440367
71
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/bucket.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2020, Intel Corporation */ /* * bucket.c -- bucket implementation * * Buckets manage volatile state of the heap. They are the abstraction layer * between the heap-managed chunks/runs and memory allocations. * * Each bucket instance can have a different u...
2,251
21.52
79
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/container_seglists.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2019, Intel Corporation */ /* * container_seglists.c -- implementation of segregated lists block container * * This container is constructed from N (up to 64) intrusive lists and a * single 8 byte bitmap that stores the information whether a given list is ...
4,215
23.511628
80
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/tx.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2019, Intel Corporation */ /* * tx.h -- internal definitions for transactions */ #ifndef LIBPMEMOBJ_INTERNAL_TX_H #define LIBPMEMOBJ_INTERNAL_TX_H 1 #include <stdint.h> #include "obj.h" #include "ulog.h" #ifdef __cplusplus extern "C" { #endif #define TX_...
1,258
22.314815
68
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/critnib.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2018-2019, Intel Corporation */ /* * critnib.c -- implementation of critnib tree * * It offers identity lookup (like a hashmap) and <= lookup (like a search * tree). Unlike some hashing algorithms (cuckoo hash, perfect hashing) the * complexity isn't constant...
15,052
22.087423
78
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/memblock.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2020, Intel Corporation */ /* * memblock.h -- internal definitions for memory block */ #ifndef LIBPMEMOBJ_MEMBLOCK_H #define LIBPMEMOBJ_MEMBLOCK_H 1 #include <stddef.h> #include <stdint.h> #include "os_thread.h" #include "heap_layout.h" #include "memops.h...
10,750
34.019544
80
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/pmalloc.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2020, Intel Corporation */ /* * pmalloc.c -- implementation of pmalloc POSIX-like API * * This is the front-end part of the persistent memory allocator. It uses both * transient and persistent representation of the heap to provide memory blocks * in a rea...
18,444
22.114035
79
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/pmemops.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2018, Intel Corporation */ #ifndef LIBPMEMOBJ_PMEMOPS_H #define LIBPMEMOBJ_PMEMOPS_H 1 #include <stddef.h> #include <stdint.h> #include "util.h" #ifdef __cplusplus extern "C" { #endif typedef int (*persist_fn)(void *base, const void *, size_t, unsigned); ty...
2,672
22.866071
80
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/sync.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2018, Intel Corporation */ /* * sync.h -- internal to obj synchronization API */ #ifndef LIBPMEMOBJ_SYNC_H #define LIBPMEMOBJ_SYNC_H 1 #include <errno.h> #include <stdint.h> #include "libpmemobj.h" #include "out.h" #include "os_thread.h" #ifdef __cpluspl...
2,504
21.168142
79
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/sync.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2018, Intel Corporation */ /* * sync.c -- persistent memory resident synchronization primitives */ #include <inttypes.h> #include "obj.h" #include "out.h" #include "util.h" #include "sync.h" #include "sys_util.h" #include "util.h" #include "valgrind_intern...
16,501
24.664075
80
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/lane.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2019, Intel Corporation */ /* * lane.h -- internal definitions for lanes */ #ifndef LIBPMEMOBJ_LANE_H #define LIBPMEMOBJ_LANE_H 1 #include <stdint.h> #include "ulog.h" #include "libpmemobj.h" #ifdef __cplusplus extern "C" { #endif /* * Distance between ...
4,652
30.02
80
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/ulog.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2020, Intel Corporation */ /* * ulog.h -- unified log public interface */ #ifndef LIBPMEMOBJ_ULOG_H #define LIBPMEMOBJ_ULOG_H 1 #include <stddef.h> #include <stdint.h> #include <time.h> #include "vec.h" #include "pmemops.h" #include<x86intrin.h> ////cmd...
6,600
32.170854
104
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/libpmemobj/lane.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2019, Intel Corporation */ /* * lane.c -- lane implementation */ #ifndef _GNU_SOURCE #define _GNU_SOURCE #endif #include <inttypes.h> #include <errno.h> #include <limits.h> #include <sched.h> #include "libpmemobj.h" #include "critnib.h" #include "lane.h" ...
12,994
21.678883
79
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/rpmem_obc/rpmem_obc_test_common.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2018, Intel Corporation */ /* * rpmem_obc_test_common.h -- common declarations for rpmem_obc test */ #include "unittest.h" #include "out.h" #include "librpmem.h" #include "rpmem.h" #include "rpmem_proto.h" #include "rpmem_common.h" #include "rpmem_util.h" ...
2,951
26.082569
71
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/rpmem_obc/rpmem_obc_test_create.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2018, Intel Corporation */ /* * rpmem_obc_test_create.c -- test cases for rpmem_obc_create function */ #include "rpmem_obc_test_common.h" static const struct rpmem_msg_create_resp CREATE_RESP = { .hdr = { .type = RPMEM_MSG_TYPE_CREATE_RESP, .size = si...
6,642
20.498382
80
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/rpmem_obc/rpmem_obc_test.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2017, Intel Corporation */ /* * rpmem_obc_test.c -- unit test for rpmem_obc module */ #include "rpmem_obc_test_common.h" #include "pmemcommon.h" /* * test_cases -- available test cases */ static struct test_case test_cases[] = { TEST_CASE(client_enotcon...
1,388
20.369231
59
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/rpmem_obc/rpmem_obc_test_open.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2018, Intel Corporation */ /* * rpmem_obc_test_open.c -- test cases for rpmem_obj_open function */ #include "rpmem_obc_test_common.h" static const struct rpmem_msg_open_resp OPEN_RESP = { .hdr = { .type = RPMEM_MSG_TYPE_OPEN_RESP, .size = sizeof(struc...
7,427
21.306306
76
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/rpmemd_db/rpmemd_db_test.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2020, Intel Corporation */ /* * rpmemd_db_test.c -- unit test for pool set database * * usage: rpmemd_db <log-file> <root_dir> <pool_desc_1> <pool_desc_2> */ #include "file.h" #include "unittest.h" #include "librpmem.h" #include "rpmemd_db.h" #include "rp...
15,339
22.636364
72
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/pmem2_granularity/pmem2_granularity.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2019-2020, Intel Corporation */ /* * pmem2_granularity.c -- test for graunlarity functionality */ #include <stdio.h> #include <stdlib.h> #include <string.h> #include "config.h" #include "source.h" #include "pmem2_granularity.h" #include "unittest.h" #include "u...
7,665
23.106918
74
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/pmem2_granularity/mocks_posix.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2019, Intel Corporation */ /* * mocks_posix.c -- mocked functions used in auto_flush_linux.c */ #include <fts.h> #include "map.h" #include "../common/mmap.h" #include "fs.h" #include "unittest.h" #define BUS_DEVICE_PATH "/sys/bus/nd/devices" /* * mmap - mock m...
2,302
23.5
63
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/pmem2_granularity/mocks_dax_windows.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2019, Intel Corporation */ /* * mocks_dax_windows.c -- mocked function required to control * FILE_DAX_VOLUME value reported by the OS APIs */ #include "unittest.h" FUNC_MOCK_DLLIMPORT(GetVolumeInformationByHandleW, BOOL, HANDLE hFile, LPWSTR lpVolumeNameBuff...
688
22.758621
61
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/pmem2_granularity/mocks_dax_windows.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2019, Intel Corporation */ /* * mocks_dax_windows.h -- redefinitions of GetVolumeInformationByHandleW * * This file is Windows-specific. * * This file should be included (i.e. using Forced Include) by libpmem2 * files, when compiled for the purpose of pmem2_g...
956
28.90625
77
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/rpmem_fip/rpmem_fip_test.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2020, Intel Corporation */ /* * rpmem_fip_test.c -- tests for rpmem_fip and rpmemd_fip modules */ #include <netdb.h> #include <sys/socket.h> #include <netinet/in.h> #include <arpa/inet.h> #include "unittest.h" #include "pmemcommon.h" #include "librpmem.h" ...
22,586
21.97762
78
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/rpmem_fip/rpmem_fip_oob.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016, Intel Corporation */ /* * rpmem_fip_sock.h -- simple oob connection implementation for exchanging * required RDMA related data */ #include <stdint.h> #include <netinet/in.h> typedef struct rpmem_ssh client_t; client_t *client_exchange(struct rpmem_targe...
743
24.655172
74
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/pmem2_source/pmem2_source.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2019-2020, Intel Corporation */ /* * pmem2_source.c -- pmem2_source unittests */ #include "fault_injection.h" #include "libpmem2.h" #include "unittest.h" #include "ut_pmem2_utils.h" #include "ut_pmem2_config.h" #include "source.h" #include "out.h" /* * verify_f...
7,608
20.433803
77
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/tools/ddmap/ddmap.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2014-2018, Intel Corporation */ /* * ddmap.c -- simple app for reading and writing data from/to a regular file or * dax device using mmap instead of file io API */ #include <stdio.h> #include <unistd.h> #include <getopt.h> #include <stdlib.h> #include <sys/mman...
11,872
22.280392
79
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/tools/dllview/dllview.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2014-2018, Intel Corporation */ /* * dllview.c -- a simple utility displaying the list of symbols exported by DLL * * usage: dllview filename */ #include <windows.h> #include <stdio.h> #include <winnt.h> #include <imagehlp.h> #include "util.h" int main(int ar...
1,233
20.649123
79
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/tools/cmpmap/cmpmap.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2017-2019, Intel Corporation */ /* * cmpmap -- a tool for comparing files using mmap */ #include <stdlib.h> #include <stdio.h> #include <getopt.h> #include <sys/mman.h> #include <assert.h> #include <string.h> #include <errno.h> #include <unistd.h> #include "file...
5,918
20.291367
73
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/tools/ctrld/signals_linux.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2017, Intel Corporation */ /* * signals_linux.h - Signal definitions for Linux */ #ifndef _SIGNALS_LINUX_H #define _SIGNALS_LINUX_H 1 #define SIGNAL_2_STR(sig) [sig] = #sig static const char *signal2str[] = { SIGNAL_2_STR(SIGHUP), /* 1 */ SIGNAL_2_STR(SIGINT)...
1,322
27.148936
49
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/tools/ctrld/signals_freebsd.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2017, Intel Corporation */ /* * signals_fbsd.h - Signal definitions for FreeBSD */ #ifndef _SIGNALS_FBSD_H #define _SIGNALS_FBSD_H 1 #define SIGNAL_2_STR(sig) [sig] = #sig static const char *signal2str[] = { SIGNAL_2_STR(SIGHUP), /* 1 */ SIGNAL_2_STR(SIGINT)...
1,386
26.74
50
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/obj_locks/obj_locks.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016-2020, Intel Corporation */ /* * obj_locks.c -- unit test for PMEMmutex, PMEMrwlock and PMEMcond */ #include <sys/param.h> #include <string.h> #include "unittest.h" #include "libpmemobj.h" #define LAYOUT_NAME "obj_locks" #define NUM_THREADS 16 #define MAX_F...
4,821
22.99005
72
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/libpmempool_feature/libpmempool_feature.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016, Intel Corporation */ /* * libpmempool_feature -- pmempool_feature_(enable|disable|query) test * */ #include <stddef.h> #include <stdlib.h> #include <stdio.h> #include "libpmempool.h" #include "pool_hdr.h" #include "unittest.h" #define EMPTY_FLAGS 0 /* ...
1,622
20.077922
72
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/obj_tx_flow/obj_tx_flow.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2020, Intel Corporation */ /* * obj_tx_flow.c -- unit test for transaction flow */ #include "unittest.h" #include "obj.h" #define LAYOUT_NAME "direct" #define TEST_VALUE_A 5 #define TEST_VALUE_B 10 #define TEST_VALUE_C 15 #define OPS_NUM 9 TOID_DECLARE(str...
7,445
23.574257
76
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/util_pool_hdr/util_pool_hdr.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2018-2020, Intel Corporation */ /* * util_pool_hdr.c -- unit test for pool_hdr layout and default values * * This test should be modified after every layout change. It's here to prevent * any accidental layout changes. */ #include "util.h" #include "unittest.h...
4,508
30.531469
79
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/util_map_proc/util_map_proc.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2014-2018, Intel Corporation */ /* * util_map_proc.c -- unit test for util_map() /proc parsing * * usage: util_map_proc maps_file len [len]... */ #define _GNU_SOURCE #include <dlfcn.h> #include "unittest.h" #include "util.h" #include "mmap.h" #define GIGABYT...
1,335
21.644068
60
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/win_lists/win_lists.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016, Intel Corporation */ /* * Copyright (c) 2016, Microsoft Corporation. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * * Re...
5,431
27
76
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/obj_pool/obj_pool.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2020, Intel Corporation */ /* * obj_pool.c -- unit test for pmemobj_create() and pmemobj_open() * Also tests pmemobj_(set/get)_user_data(). * * usage: obj_pool op path layout [poolsize mode] * * op can be: * c - create * o - open * * "poolsize" a...
2,905
21.527132
75
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/pmem2_memset/pmem2_memset.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2020, Intel Corporation */ /* * pmem_memset.c -- unit test for doing a memset * * usage: pmem_memset file offset length */ #include "unittest.h" #include "file.h" #include "ut_pmem2.h" #include "memset_common.h" static void do_memset_variants(int fd, char *de...
1,810
21.6375
78
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/pmem2_memset/memset_common.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2020, Intel Corporation */ /* * memset_common.c -- common part for tests doing a persistent memset */ #include "unittest.h" #include "memset_common.h" /* * do_memset - worker function for memset */ void do_memset(int fd, char *dest, const char *file_name...
2,043
24.55
69
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/pmem2_memset/memset_common.h
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2020, Intel Corporation */ /* * memset_common.h -- header file for common memset utilities */ #ifndef MEMSET_COMMON_H #define MEMSET_COMMON_H 1 #include "unittest.h" #include "file.h" extern unsigned Flags[10]; typedef void *(*memset_fn)(void *pmemdest, int c,...
552
22.041667
78
h
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/obj_pmalloc_basic/obj_pmalloc_basic.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2019, Intel Corporation */ /* * obj_pmalloc_basic.c -- unit test for pmalloc interface */ #include <stdint.h> #include "heap.h" #include "obj.h" #include "pmalloc.h" #include "unittest.h" #include "valgrind_internal.h" #include "set.h" #define MOCK_POOL_SI...
8,962
23.15903
78
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/win_common/win_common.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2017, Intel Corporation */ /* * Copyright (c) 2016, Microsoft Corporation. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * * Re...
3,080
35.678571
74
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/obj_realloc/obj_realloc.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2019, Intel Corporation */ /* * obj_realloc.c -- unit test for pmemobj_realloc and pmemobj_zrealloc */ #include <sys/param.h> #include <string.h> #include "unittest.h" #include "heap.h" #include "alloc_class.h" #include "obj.h" #include "util.h" #define M...
7,788
24.371336
70
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/pmem_deep_persist/mocks_posix.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2018-2020, Intel Corporation */ /* * mocks_posix.c -- redefinitions of open/write functions (Posix implementation) */ #include "util.h" #include "os.h" #include "unittest.h" /* * open -- open mock because of Dev DAX without deep_flush * sysfs file, eg. DAX o...
1,326
20.754098
80
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/obj_tx_free/obj_tx_free.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2020, Intel Corporation */ /* * obj_tx_free.c -- unit test for pmemobj_tx_free */ #include <sys/param.h> #include <string.h> #include "unittest.h" #include "util.h" #include "valgrind_internal.h" #define LAYOUT_NAME "tx_free" #define OBJ_SIZE (200 * 1024)...
11,423
21.356164
78
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/util_uuid_generate/util_uuid_generate.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2016, Intel Corporation */ /* * util_uuid_generate.c -- unit test for generating a uuid * * usage: util_uuid_generate [string] [valid|invalid] */ #include "unittest.h" #include "uuid.h" #include <unistd.h> #include <string.h> int main(int argc, char *argv[]) ...
1,885
21.722892
62
c
null
NearPMSW-main/nearpm/shadow/pmdk-sd/src/test/obj_pool_lookup/obj_pool_lookup.c
// SPDX-License-Identifier: BSD-3-Clause /* Copyright 2015-2018, Intel Corporation */ /* * obj_pool_lookup.c -- unit test for pmemobj_pool and pmemobj_pool_of */ #include "unittest.h" #define MAX_PATH_LEN 255 #define LAYOUT_NAME "pool_lookup" #define ALLOC_SIZE 100 static void define_path(char *str, size_t size, ...
3,576
26.305344
70
c