]> git.ipfire.org Git - thirdparty/gcc.git/blob - liboffloadmic/runtime/emulator/myo_service.cpp
e18abecd05cdc2a44e5e31c1160ce680ca302f2e
[thirdparty/gcc.git] / liboffloadmic / runtime / emulator / myo_service.cpp
1 /*
2 Copyright (c) 2014 Intel Corporation. All Rights Reserved.
3
4 Redistribution and use in source and binary forms, with or without
5 modification, are permitted provided that the following conditions
6 are met:
7
8 * Redistributions of source code must retain the above copyright
9 notice, this list of conditions and the following disclaimer.
10 * Redistributions in binary form must reproduce the above copyright
11 notice, this list of conditions and the following disclaimer in the
12 documentation and/or other materials provided with the distribution.
13 * Neither the name of Intel Corporation nor the names of its
14 contributors may be used to endorse or promote products derived
15 from this software without specific prior written permission.
16
17 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
18 "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
19 LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
20 A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
21 HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
22 SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
23 LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
24 DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
25 THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
27 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28 */
29
30 #include "myo_service.h"
31
32 #include "myo_version_asm.h"
33
34
35 extern "C"
36 {
37
38 MYOACCESSAPI MyoError
39 SYMBOL_VERSION (myoAcquire, 1) ()
40 {
41 MYOTRACE ("myoAcquire");
42
43 assert (false);
44
45 return MYO_ERROR;
46 }
47
48
49 MYOACCESSAPI MyoError
50 SYMBOL_VERSION (myoRelease, 1) ()
51 {
52 MYOTRACE ("myoRelease");
53
54 assert (false);
55
56 return MYO_ERROR;
57 }
58
59
60 MYOACCESSAPI void
61 SYMBOL_VERSION (myoSharedAlignedFree, 1) (void *ptr)
62 {
63 MYOTRACE ("myoSharedAlignedFree");
64
65 assert (false);
66 }
67
68
69 MYOACCESSAPI void*
70 SYMBOL_VERSION (myoSharedAlignedMalloc, 1) (size_t size,
71 size_t alignment)
72 {
73 MYOTRACE ("myoSharedAlignedMalloc");
74
75 assert (false);
76
77 return 0;
78 }
79
80
81 MYOACCESSAPI void
82 SYMBOL_VERSION (myoSharedFree, 1) (void *ptr)
83 {
84 MYOTRACE ("myoSharedFree");
85
86 assert (false);
87 }
88
89
90 MYOACCESSAPI void*
91 SYMBOL_VERSION (myoSharedMalloc, 1) (size_t size)
92 {
93 MYOTRACE ("myoSharedMalloc");
94
95 assert (false);
96
97 return 0;
98 }
99
100
101 MYOACCESSAPI MyoError
102 SYMBOL_VERSION (myoiLibInit, 1) (void *args,
103 void *init_func)
104 {
105 MYOTRACE ("myoiLibInit");
106
107 assert (false);
108
109 return MYO_ERROR;
110 }
111
112
113 MYOACCESSAPI void
114 SYMBOL_VERSION (myoiLibFini, 1) ()
115 {
116 MYOTRACE ("myoiLibFini");
117
118 assert (false);
119 }
120
121
122 MyoError
123 SYMBOL_VERSION (myoiMicVarTableRegister, 1) (void *table,
124 int num)
125 {
126 MYOTRACE ("myoiMicVarTableRegister");
127
128 assert (false);
129
130 return MYO_ERROR;
131 }
132
133
134 MYOACCESSAPI MyoError
135 SYMBOL_VERSION (myoiRemoteFuncRegister, 1) (MyoiRemoteFuncType type,
136 const char *name)
137 {
138 MYOTRACE ("myoiRemoteFuncRegister");
139
140 /* Looks like we have nothing to do here. */
141
142 return MYO_SUCCESS;
143 }
144
145
146 MyoError
147 SYMBOL_VERSION (myoiTargetFptrTableRegister, 1) (void *table,
148 int num,
149 int ordered)
150 {
151 MYOTRACE ("myoiTargetFptrTableRegister");
152
153 assert (false);
154
155 return MYO_ERROR;
156 }
157
158 } // extern "C"
159