ubinos
ubiclib_test.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2020 Sung Ho Park and CSOS
3  *
4  * SPDX-License-Identifier: Apache-2.0
5  */
6 
7 #ifndef UBICLIB_TEST_H_
8 #define UBICLIB_TEST_H_
9 
18 #include <ubinos.h>
19 
20 #define UBICLIB_TEST_HEAPTEST_LIFETIME_TYPE__UNIFORM 1
21 #define UBICLIB_TEST_HEAPTEST_LIFETIME_TYPE__EXPONENTIAL 2
22 #define UBICLIB_TEST_HEAPTEST_LIFETIME_TYPE__NORMAL 3
23 
24 #define UBICLIB_TEST_HEAPTEST_SIZE_TYPE__UNIFORM 1
25 #define UBICLIB_TEST_HEAPTEST_SIZE_TYPE__EXPONENTIAL 2
26 #define UBICLIB_TEST_HEAPTEST_SIZE_TYPE__NORMAL 3
27 
28 #define UBICLIB_TEST_HEAPTEST_DATA_LENGTH 4000
29 
30 extern double ubiclib_test_heaptest_urx1_a[UBICLIB_TEST_HEAPTEST_DATA_LENGTH];
31 extern double ubiclib_test_heaptest_urx2_a[UBICLIB_TEST_HEAPTEST_DATA_LENGTH];
32 extern double ubiclib_test_heaptest_erx1_a[UBICLIB_TEST_HEAPTEST_DATA_LENGTH];
33 extern double ubiclib_test_heaptest_erx2_a[UBICLIB_TEST_HEAPTEST_DATA_LENGTH];
34 extern double ubiclib_test_heaptest_nrx1_a[UBICLIB_TEST_HEAPTEST_DATA_LENGTH];
35 extern double ubiclib_test_heaptest_nrx2_a[UBICLIB_TEST_HEAPTEST_DATA_LENGTH];
36 
38 {
39  int test_index;
40  unsigned int heapsize;
41  unsigned int data_length;
42  unsigned int lifetime_max;
43  unsigned int stepcount_max;
44  unsigned int size_max;
45  unsigned int size_min;
46  unsigned int mean_step;
47  unsigned int mean_min;
48  unsigned int testcount_max;
49  unsigned int critlock;
50  unsigned int blockcheck;
51  unsigned int skipfirsfull;
52 
53  int dir;
54  unsigned int algorithm_type;
55  unsigned int m;
56  unsigned int lifetime_type;
57  double *lifetime_p;
58  unsigned int size_type;
59  double *size_p;
61 
63 
65 {
66  double sm;
67  double rsm;
68  double bc;
69 
70  double ac;
71  double ata;
72  double atd;
73  double atb;
74  double atw;
75 
76  double rc;
77  double rta;
78  double rtd;
79  double rtb;
80  double rtw;
81 
82  double tfa;
83  double tfd;
84  double tfb;
85  double tfw;
86 
87  double ifa;
88  double ifd;
89  double ifb;
90  double ifw;
91 
92  double efa;
93  double efd;
94  double efb;
95  double efw;
97 
99 
100 void ubiclib_test_heaptest(void *arg);
101 
102 ubi_err_t ubiclib_test_test_all(void);
103 
104 ubi_err_t ubik_test_cbuf_test_00(void);
105 
106 #endif /* UBICLIB_TEST_H_ */
107 
Definition: ubiclib_test.h:38
Definition: ubiclib_test.h:65
ubinos API