koffi 2.14.0 → 2.15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +26 -1
- package/README.md +1 -1
- package/build/koffi/darwin_arm64/koffi.node +0 -0
- package/build/koffi/darwin_x64/koffi.node +0 -0
- package/build/koffi/freebsd_arm64/koffi.node +0 -0
- package/build/koffi/freebsd_ia32/koffi.node +0 -0
- package/build/koffi/freebsd_x64/koffi.node +0 -0
- package/build/koffi/linux_arm64/koffi.node +0 -0
- package/build/koffi/linux_armhf/koffi.node +0 -0
- package/build/koffi/linux_ia32/koffi.node +0 -0
- package/build/koffi/linux_loong64/koffi.node +0 -0
- package/build/koffi/linux_riscv64d/koffi.node +0 -0
- package/build/koffi/linux_x64/koffi.node +0 -0
- package/build/koffi/musl_arm64/koffi.node +0 -0
- package/build/koffi/musl_x64/koffi.node +0 -0
- package/build/koffi/openbsd_ia32/koffi.node +0 -0
- package/build/koffi/openbsd_x64/koffi.node +0 -0
- package/build/koffi/win32_arm64/koffi.node +0 -0
- package/build/koffi/win32_ia32/koffi.node +0 -0
- package/build/koffi/win32_x64/koffi.node +0 -0
- package/doc/assets.ini +2 -1
- package/doc/build.sh +9 -0
- package/doc/pages/404.md +17 -0
- package/doc/pages/index.md +43 -4
- package/doc/pages/misc.md +16 -11
- package/doc/pages/platforms.md +8 -19
- package/doc/pages.ini +4 -7
- package/doc/static/highlight.js +2 -14
- package/doc/static/koffi.css +3 -15
- package/doc/static/perf_windows.png +0 -0
- package/doc/static/print.css +2 -14
- package/index.d.ts +29 -24
- package/index.js +10 -9
- package/indirect.js +10 -9
- package/{src/core → lib/native}/base/base.cc +1753 -1089
- package/{src/core → lib/native}/base/base.hh +868 -572
- package/{src/core → lib/native}/base/crc.inc +3 -21
- package/lib/native/base/crc_gen.py +72 -0
- package/{src/core → lib/native}/base/mimetypes.inc +2 -20
- package/{src/core → lib/native}/base/mimetypes_gen.py +2 -21
- package/lib/native/base/tower.cc +821 -0
- package/lib/native/base/tower.hh +81 -0
- package/{src/core → lib/native}/base/unicode.inc +3 -21
- package/{src/core → lib/native}/base/unicode_gen.py +5 -42
- package/package.json +3 -2
- package/src/cnoke/assets/FindCNoke.cmake +8 -20
- package/src/cnoke/assets/win_delay_hook.c +2 -20
- package/src/cnoke/cnoke.js +2 -21
- package/src/cnoke/src/builder.js +3 -22
- package/src/cnoke/src/index.js +2 -20
- package/src/cnoke/src/tools.js +2 -20
- package/src/koffi/CMakeLists.txt +19 -22
- package/src/koffi/cmake/raylib.cmake +5 -22
- package/src/koffi/cmake/sqlite3.cmake +2 -20
- package/src/koffi/src/abi_arm32.cc +31 -49
- package/src/koffi/src/abi_arm32_asm.S +2 -20
- package/src/koffi/src/abi_arm64.cc +36 -54
- package/src/koffi/src/abi_arm64_asm.S +2 -20
- package/src/koffi/src/abi_arm64_asm.asm +2 -20
- package/src/koffi/src/abi_loong64.cc +2 -20
- package/src/koffi/src/abi_loong64_asm.S +2 -20
- package/src/koffi/src/abi_riscv64.cc +34 -52
- package/src/koffi/src/abi_riscv64_asm.S +2 -20
- package/src/koffi/src/abi_x64_sysv.cc +36 -54
- package/src/koffi/src/abi_x64_sysv_asm.S +2 -20
- package/src/koffi/src/abi_x64_win.cc +32 -50
- package/src/koffi/src/abi_x64_win_asm.asm +2 -20
- package/src/koffi/src/abi_x86.cc +33 -51
- package/src/koffi/src/abi_x86_asm.S +2 -20
- package/src/koffi/src/abi_x86_asm.asm +2 -20
- package/src/koffi/src/call.cc +107 -281
- package/src/koffi/src/call.hh +9 -27
- package/src/koffi/src/errno.inc +2 -20
- package/src/koffi/src/ffi.cc +121 -121
- package/src/koffi/src/ffi.hh +23 -38
- package/src/koffi/src/init.js +2 -20
- package/src/koffi/src/parser.cc +15 -29
- package/src/koffi/src/parser.hh +4 -22
- package/src/koffi/src/trampolines/armasm.inc +0 -21
- package/src/koffi/src/trampolines/gnu.inc +0 -21
- package/src/koffi/src/trampolines/masm32.inc +0 -21
- package/src/koffi/src/trampolines/masm64.inc +0 -21
- package/src/koffi/src/trampolines/prototypes.inc +1 -22
- package/src/koffi/src/util.cc +87 -102
- package/src/koffi/src/util.hh +11 -29
- package/src/koffi/src/uv.cc +193 -0
- package/src/koffi/src/uv.def +10 -0
- package/src/koffi/src/uv.hh +40 -0
- package/src/koffi/src/win32.cc +7 -25
- package/src/koffi/src/win32.hh +4 -22
- package/vendor/node-api-headers/include/uv/aix.h +32 -0
- package/vendor/node-api-headers/include/uv/bsd.h +34 -0
- package/vendor/node-api-headers/include/uv/darwin.h +61 -0
- package/vendor/node-api-headers/include/uv/errno.h +483 -0
- package/vendor/node-api-headers/include/uv/linux.h +34 -0
- package/vendor/node-api-headers/include/uv/os390.h +33 -0
- package/vendor/node-api-headers/include/uv/posix.h +31 -0
- package/vendor/node-api-headers/include/uv/sunos.h +44 -0
- package/vendor/node-api-headers/include/uv/threadpool.h +37 -0
- package/vendor/node-api-headers/include/uv/tree.h +521 -0
- package/vendor/node-api-headers/include/uv/unix.h +512 -0
- package/vendor/node-api-headers/include/uv/version.h +43 -0
- package/vendor/node-api-headers/include/uv/win.h +698 -0
- package/vendor/node-api-headers/include/uv.h +1990 -0
- package/src/core/base/crc_gen.py +0 -109
package/src/koffi/src/ffi.hh
CHANGED
|
@@ -1,41 +1,23 @@
|
|
|
1
|
-
//
|
|
2
|
-
//
|
|
3
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
4
|
-
// this software and associated documentation files (the “Software”), to deal in
|
|
5
|
-
// the Software without restriction, including without limitation the rights to use,
|
|
6
|
-
// copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the
|
|
7
|
-
// Software, and to permit persons to whom the Software is furnished to do so,
|
|
8
|
-
// subject to the following conditions:
|
|
9
|
-
//
|
|
10
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
11
|
-
// copies or substantial portions of the Software.
|
|
12
|
-
//
|
|
13
|
-
// THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND,
|
|
14
|
-
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
|
15
|
-
// OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
16
|
-
// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
|
17
|
-
// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
18
|
-
// WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
19
|
-
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
20
|
-
// OTHER DEALINGS IN THE SOFTWARE.
|
|
1
|
+
// SPDX-License-Identifier: MIT
|
|
2
|
+
// SPDX-FileCopyrightText: 2025 Niels Martignène <niels.martignene@protonmail.com>
|
|
21
3
|
|
|
22
4
|
#pragma once
|
|
23
5
|
|
|
24
|
-
#include "
|
|
6
|
+
#include "lib/native/base/base.hh"
|
|
25
7
|
|
|
26
8
|
#include <napi.h>
|
|
27
9
|
|
|
28
|
-
namespace
|
|
10
|
+
namespace K {
|
|
29
11
|
|
|
30
12
|
static const Size DefaultSyncStackSize = Mebibytes(1);
|
|
31
13
|
static const Size DefaultSyncHeapSize = Mebibytes(2);
|
|
32
|
-
static const Size DefaultAsyncStackSize = Kibibytes(
|
|
33
|
-
static const Size DefaultAsyncHeapSize = Kibibytes(
|
|
34
|
-
static const int DefaultResidentAsyncPools =
|
|
35
|
-
static const int DefaultMaxAsyncCalls =
|
|
14
|
+
static const Size DefaultAsyncStackSize = Kibibytes(128);
|
|
15
|
+
static const Size DefaultAsyncHeapSize = Kibibytes(128);
|
|
16
|
+
static const int DefaultResidentAsyncPools = 4;
|
|
17
|
+
static const int DefaultMaxAsyncCalls = 256;
|
|
36
18
|
static const Size DefaultMaxTypeSize = Mebibytes(64);
|
|
37
19
|
|
|
38
|
-
static const int MaxAsyncCalls =
|
|
20
|
+
static const int MaxAsyncCalls = 4096;
|
|
39
21
|
static const Size MaxParameters = 64;
|
|
40
22
|
static const Size MaxTrampolines = 8192;
|
|
41
23
|
|
|
@@ -47,17 +29,17 @@ enum class PrimitiveKind {
|
|
|
47
29
|
Int8,
|
|
48
30
|
UInt8,
|
|
49
31
|
Int16,
|
|
50
|
-
Int16S,
|
|
32
|
+
Int16S, // Keep behind Int16
|
|
51
33
|
UInt16,
|
|
52
|
-
UInt16S,
|
|
34
|
+
UInt16S, // Keep behind UInt16
|
|
53
35
|
Int32,
|
|
54
|
-
Int32S,
|
|
36
|
+
Int32S, // Keep behind Int32
|
|
55
37
|
UInt32,
|
|
56
|
-
UInt32S,
|
|
38
|
+
UInt32S, // Keep behind UInt32
|
|
57
39
|
Int64,
|
|
58
|
-
Int64S,
|
|
40
|
+
Int64S, // Keep behind Int64
|
|
59
41
|
UInt64,
|
|
60
|
-
UInt64S,
|
|
42
|
+
UInt64S, // Keep behind UInt64
|
|
61
43
|
String,
|
|
62
44
|
String16,
|
|
63
45
|
String32,
|
|
@@ -152,7 +134,7 @@ struct TypeInfo {
|
|
|
152
134
|
mutable Napi::FunctionReference construct; // Union only
|
|
153
135
|
mutable Napi::ObjectReference defn;
|
|
154
136
|
|
|
155
|
-
|
|
137
|
+
K_HASHTABLE_HANDLER(TypeInfo, name);
|
|
156
138
|
};
|
|
157
139
|
|
|
158
140
|
struct RecordMember {
|
|
@@ -269,7 +251,7 @@ struct InstanceMemory {
|
|
|
269
251
|
|
|
270
252
|
uint16_t generation; // Can wrap without risk
|
|
271
253
|
|
|
272
|
-
|
|
254
|
+
bool busy;
|
|
273
255
|
bool temporary;
|
|
274
256
|
int depth;
|
|
275
257
|
};
|
|
@@ -294,8 +276,8 @@ struct InstanceData {
|
|
|
294
276
|
|
|
295
277
|
Napi::Symbol active_symbol;
|
|
296
278
|
|
|
297
|
-
std::mutex
|
|
298
|
-
LocalArray<InstanceMemory *,
|
|
279
|
+
std::mutex mem_mutex;
|
|
280
|
+
LocalArray<InstanceMemory *, 17> memories;
|
|
299
281
|
int temporaries = 0;
|
|
300
282
|
|
|
301
283
|
std::thread::id main_thread_id;
|
|
@@ -329,7 +311,7 @@ struct InstanceData {
|
|
|
329
311
|
int64_t disposed = 0;
|
|
330
312
|
} stats;
|
|
331
313
|
};
|
|
332
|
-
static_assert(DefaultResidentAsyncPools <=
|
|
314
|
+
static_assert(DefaultResidentAsyncPools <= K_LEN(InstanceData::memories.data) - 1);
|
|
333
315
|
static_assert(DefaultMaxAsyncCalls >= DefaultResidentAsyncPools);
|
|
334
316
|
static_assert(MaxAsyncCalls >= DefaultMaxAsyncCalls);
|
|
335
317
|
|
|
@@ -362,6 +344,9 @@ static_assert(MaxTrampolines <= INT16_MAX);
|
|
|
362
344
|
|
|
363
345
|
extern SharedData shared;
|
|
364
346
|
|
|
347
|
+
InstanceMemory *AllocateMemory(InstanceData *instance, Size stack_size, Size heap_size);
|
|
348
|
+
void ReleaseMemory(InstanceData *instance, InstanceMemory *mem);
|
|
349
|
+
|
|
365
350
|
Napi::Value TranslateNormalCall(const Napi::CallbackInfo &info);
|
|
366
351
|
Napi::Value TranslateVariadicCall(const Napi::CallbackInfo &info);
|
|
367
352
|
Napi::Value TranslateAsyncCall(const Napi::CallbackInfo &info);
|
package/src/koffi/src/init.js
CHANGED
|
@@ -1,23 +1,5 @@
|
|
|
1
|
-
//
|
|
2
|
-
//
|
|
3
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
4
|
-
// this software and associated documentation files (the “Software”), to deal in
|
|
5
|
-
// the Software without restriction, including without limitation the rights to use,
|
|
6
|
-
// copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the
|
|
7
|
-
// Software, and to permit persons to whom the Software is furnished to do so,
|
|
8
|
-
// subject to the following conditions:
|
|
9
|
-
//
|
|
10
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
11
|
-
// copies or substantial portions of the Software.
|
|
12
|
-
//
|
|
13
|
-
// THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND,
|
|
14
|
-
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
|
15
|
-
// OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
16
|
-
// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
|
17
|
-
// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
18
|
-
// WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
19
|
-
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
20
|
-
// OTHER DEALINGS IN THE SOFTWARE.
|
|
1
|
+
// SPDX-License-Identifier: MIT
|
|
2
|
+
// SPDX-FileCopyrightText: 2025 Niels Martignène <niels.martignene@protonmail.com>
|
|
21
3
|
|
|
22
4
|
const fs = require('fs');
|
|
23
5
|
const path = require('path');
|
package/src/koffi/src/parser.cc
CHANGED
|
@@ -1,31 +1,13 @@
|
|
|
1
|
-
//
|
|
2
|
-
//
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
// the Software without restriction, including without limitation the rights to use,
|
|
6
|
-
// copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the
|
|
7
|
-
// Software, and to permit persons to whom the Software is furnished to do so,
|
|
8
|
-
// subject to the following conditions:
|
|
9
|
-
//
|
|
10
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
11
|
-
// copies or substantial portions of the Software.
|
|
12
|
-
//
|
|
13
|
-
// THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND,
|
|
14
|
-
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
|
15
|
-
// OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
16
|
-
// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
|
17
|
-
// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
18
|
-
// WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
19
|
-
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
20
|
-
// OTHER DEALINGS IN THE SOFTWARE.
|
|
21
|
-
|
|
22
|
-
#include "src/core/base/base.hh"
|
|
1
|
+
// SPDX-License-Identifier: MIT
|
|
2
|
+
// SPDX-FileCopyrightText: 2025 Niels Martignène <niels.martignene@protonmail.com>
|
|
3
|
+
|
|
4
|
+
#include "lib/native/base/base.hh"
|
|
23
5
|
#include "ffi.hh"
|
|
24
6
|
#include "parser.hh"
|
|
25
7
|
|
|
26
8
|
#include <napi.h>
|
|
27
9
|
|
|
28
|
-
namespace
|
|
10
|
+
namespace K {
|
|
29
11
|
|
|
30
12
|
bool PrototypeParser::Parse(const char *str, bool concrete, FunctionInfo *out_func)
|
|
31
13
|
{
|
|
@@ -164,12 +146,16 @@ const TypeInfo *PrototypeParser::ParseType(int *out_directions)
|
|
|
164
146
|
}
|
|
165
147
|
offset--;
|
|
166
148
|
|
|
167
|
-
if (out_directions
|
|
168
|
-
|
|
149
|
+
if (out_directions) {
|
|
150
|
+
if (offset > start) {
|
|
151
|
+
int directions = ResolveDirections(tokens[start]);
|
|
169
152
|
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
153
|
+
if (directions) {
|
|
154
|
+
*out_directions = directions;
|
|
155
|
+
start++;
|
|
156
|
+
} else {
|
|
157
|
+
*out_directions = 1;
|
|
158
|
+
}
|
|
173
159
|
} else {
|
|
174
160
|
*out_directions = 1;
|
|
175
161
|
}
|
|
@@ -221,7 +207,7 @@ bool PrototypeParser::Match(const char *expect)
|
|
|
221
207
|
|
|
222
208
|
bool PrototypeParser::IsIdentifier(Span<const char> tok) const
|
|
223
209
|
{
|
|
224
|
-
|
|
210
|
+
K_ASSERT(tok.len);
|
|
225
211
|
return IsAsciiAlpha(tok[0]) || tok[0] == '_';
|
|
226
212
|
}
|
|
227
213
|
|
package/src/koffi/src/parser.hh
CHANGED
|
@@ -1,32 +1,14 @@
|
|
|
1
|
-
//
|
|
2
|
-
//
|
|
3
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
4
|
-
// this software and associated documentation files (the “Software”), to deal in
|
|
5
|
-
// the Software without restriction, including without limitation the rights to use,
|
|
6
|
-
// copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the
|
|
7
|
-
// Software, and to permit persons to whom the Software is furnished to do so,
|
|
8
|
-
// subject to the following conditions:
|
|
9
|
-
//
|
|
10
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
11
|
-
// copies or substantial portions of the Software.
|
|
12
|
-
//
|
|
13
|
-
// THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND,
|
|
14
|
-
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
|
15
|
-
// OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
16
|
-
// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
|
17
|
-
// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
18
|
-
// WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
19
|
-
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
20
|
-
// OTHER DEALINGS IN THE SOFTWARE.
|
|
1
|
+
// SPDX-License-Identifier: MIT
|
|
2
|
+
// SPDX-FileCopyrightText: 2025 Niels Martignène <niels.martignene@protonmail.com>
|
|
21
3
|
|
|
22
4
|
#pragma once
|
|
23
5
|
|
|
24
|
-
#include "
|
|
6
|
+
#include "lib/native/base/base.hh"
|
|
25
7
|
#include "util.hh"
|
|
26
8
|
|
|
27
9
|
#include <napi.h>
|
|
28
10
|
|
|
29
|
-
namespace
|
|
11
|
+
namespace K {
|
|
30
12
|
|
|
31
13
|
struct InstanceData;
|
|
32
14
|
struct TypeInfo;
|
|
@@ -1,24 +1,3 @@
|
|
|
1
|
-
; Copyright (C) 2025 Niels Martignène <niels.martignene@protonmail.com>
|
|
2
|
-
;
|
|
3
|
-
; Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
4
|
-
; this software and associated documentation files (the “Software”), to deal in
|
|
5
|
-
; the Software without restriction, including without limitation the rights to use,
|
|
6
|
-
; copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the
|
|
7
|
-
; Software, and to permit persons to whom the Software is furnished to do so,
|
|
8
|
-
; subject to the following conditions:
|
|
9
|
-
;
|
|
10
|
-
; The above copyright notice and this permission notice shall be included in all
|
|
11
|
-
; copies or substantial portions of the Software.
|
|
12
|
-
;
|
|
13
|
-
; THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND,
|
|
14
|
-
; EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
|
15
|
-
; OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
16
|
-
; NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
|
17
|
-
; HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
18
|
-
; WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
19
|
-
; FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
20
|
-
; OTHER DEALINGS IN THE SOFTWARE.
|
|
21
|
-
|
|
22
1
|
EXPORT Trampoline0
|
|
23
2
|
EXPORT Trampoline1
|
|
24
3
|
EXPORT Trampoline2
|
|
@@ -1,24 +1,3 @@
|
|
|
1
|
-
# Copyright (C) 2025 Niels Martignène <niels.martignene@protonmail.com>
|
|
2
|
-
#
|
|
3
|
-
# Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
4
|
-
# this software and associated documentation files (the “Software”), to deal in
|
|
5
|
-
# the Software without restriction, including without limitation the rights to use,
|
|
6
|
-
# copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the
|
|
7
|
-
# Software, and to permit persons to whom the Software is furnished to do so,
|
|
8
|
-
# subject to the following conditions:
|
|
9
|
-
#
|
|
10
|
-
# The above copyright notice and this permission notice shall be included in all
|
|
11
|
-
# copies or substantial portions of the Software.
|
|
12
|
-
#
|
|
13
|
-
# THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND,
|
|
14
|
-
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
|
15
|
-
# OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
16
|
-
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
|
17
|
-
# HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
18
|
-
# WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
19
|
-
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
20
|
-
# OTHER DEALINGS IN THE SOFTWARE.
|
|
21
|
-
|
|
22
1
|
.global SYMBOL(Trampoline0)
|
|
23
2
|
.global SYMBOL(Trampoline1)
|
|
24
3
|
.global SYMBOL(Trampoline2)
|
|
@@ -1,24 +1,3 @@
|
|
|
1
|
-
; Copyright (C) 2025 Niels Martignène <niels.martignene@protonmail.com>
|
|
2
|
-
;
|
|
3
|
-
; Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
4
|
-
; this software and associated documentation files (the “Software”), to deal in
|
|
5
|
-
; the Software without restriction, including without limitation the rights to use,
|
|
6
|
-
; copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the
|
|
7
|
-
; Software, and to permit persons to whom the Software is furnished to do so,
|
|
8
|
-
; subject to the following conditions:
|
|
9
|
-
;
|
|
10
|
-
; The above copyright notice and this permission notice shall be included in all
|
|
11
|
-
; copies or substantial portions of the Software.
|
|
12
|
-
;
|
|
13
|
-
; THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND,
|
|
14
|
-
; EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
|
15
|
-
; OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
16
|
-
; NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
|
17
|
-
; HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
18
|
-
; WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
19
|
-
; FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
20
|
-
; OTHER DEALINGS IN THE SOFTWARE.
|
|
21
|
-
|
|
22
1
|
public Trampoline0
|
|
23
2
|
public Trampoline1
|
|
24
3
|
public Trampoline2
|
|
@@ -1,24 +1,3 @@
|
|
|
1
|
-
; Copyright (C) 2025 Niels Martignène <niels.martignene@protonmail.com>
|
|
2
|
-
;
|
|
3
|
-
; Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
4
|
-
; this software and associated documentation files (the “Software”), to deal in
|
|
5
|
-
; the Software without restriction, including without limitation the rights to use,
|
|
6
|
-
; copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the
|
|
7
|
-
; Software, and to permit persons to whom the Software is furnished to do so,
|
|
8
|
-
; subject to the following conditions:
|
|
9
|
-
;
|
|
10
|
-
; The above copyright notice and this permission notice shall be included in all
|
|
11
|
-
; copies or substantial portions of the Software.
|
|
12
|
-
;
|
|
13
|
-
; THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND,
|
|
14
|
-
; EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
|
15
|
-
; OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
16
|
-
; NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
|
17
|
-
; HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
18
|
-
; WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
19
|
-
; FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
20
|
-
; OTHER DEALINGS IN THE SOFTWARE.
|
|
21
|
-
|
|
22
1
|
public Trampoline0
|
|
23
2
|
public Trampoline1
|
|
24
3
|
public Trampoline2
|
|
@@ -1,24 +1,3 @@
|
|
|
1
|
-
// Copyright (C) 2025 Niels Martignène <niels.martignene@protonmail.com>
|
|
2
|
-
//
|
|
3
|
-
// Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
4
|
-
// this software and associated documentation files (the “Software”), to deal in
|
|
5
|
-
// the Software without restriction, including without limitation the rights to use,
|
|
6
|
-
// copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the
|
|
7
|
-
// Software, and to permit persons to whom the Software is furnished to do so,
|
|
8
|
-
// subject to the following conditions:
|
|
9
|
-
//
|
|
10
|
-
// The above copyright notice and this permission notice shall be included in all
|
|
11
|
-
// copies or substantial portions of the Software.
|
|
12
|
-
//
|
|
13
|
-
// THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND,
|
|
14
|
-
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
|
15
|
-
// OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
16
|
-
// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
|
17
|
-
// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
18
|
-
// WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
19
|
-
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
20
|
-
// OTHER DEALINGS IN THE SOFTWARE.
|
|
21
|
-
|
|
22
1
|
extern "C" int Trampoline0; extern "C" int TrampolineX0;
|
|
23
2
|
extern "C" int Trampoline1; extern "C" int TrampolineX1;
|
|
24
3
|
extern "C" int Trampoline2; extern "C" int TrampolineX2;
|
|
@@ -16406,4 +16385,4 @@ static void *const Trampolines[][2] = {
|
|
|
16406
16385
|
{ &Trampoline8190, &TrampolineX8190 },
|
|
16407
16386
|
{ &Trampoline8191, &TrampolineX8191 }
|
|
16408
16387
|
};
|
|
16409
|
-
static_assert(
|
|
16388
|
+
static_assert(K_LEN(Trampolines) == MaxTrampolines);
|