toggle menu
korge-root
5.1.0
common
switch theme
search in API
korge-core
/
korlibs.wasm
/
WasmRuntime
Wasm
Runtime
open
class
WasmRuntime
(
module
:
WasmModule
,
val
memSize
:
Int
,
val
memMax
:
Int
)
Inheritors
WasmRunInterpreter
WasmRunJVMJIT
Members
Constructors
Wasm
Runtime
Link copied to clipboard
constructor
(
module
:
WasmModule
,
memSize
:
Int
,
memMax
:
Int
)
Types
Companion
Link copied to clipboard
object
Companion
Wasm
Func
Call
Link copied to clipboard
interface
WasmFuncCall
Wasm
Table
Link copied to clipboard
class
WasmTable
(
val
limit
:
WasmType.Limit
)
Properties
exported
Link copied to clipboard
open
val
exported
:
Set
<
String
>
functions
Link copied to clipboard
val
functions
:
LinkedHashMap
<
String
,
LinkedHashMap
<
String
,
WasmRuntime
.
(
Array
<
Any
?
>
)
->
Any
?
>
>
instructions
Executed
Link copied to clipboard
var
instructionsExecuted
:
Long
mem
Max
Link copied to clipboard
val
memMax
:
Int
memory
Link copied to clipboard
var
memory
:
Buffer
memory
Num
Pages
Link copied to clipboard
val
memoryNumPages
:
Int
mem
Size
Link copied to clipboard
val
memSize
:
Int
tables
Link copied to clipboard
val
tables
:
List
<
WasmRuntime.WasmTable
>
trace
Link copied to clipboard
var
trace
:
Boolean
used
Class
Memory
Link copied to clipboard
var
usedClassMemory
:
Int
Functions
alloc
Link copied to clipboard
fun
alloc
(
size
:
Int
)
:
Int
alloc
And
Write
Link copied to clipboard
fun
allocAndWrite
(
data
:
ByteArray
)
:
Int
close
Link copied to clipboard
open
fun
close
(
)
free
Link copied to clipboard
fun
free
(
ptr
:
Int
)
fun
free
(
vararg
ptrs
:
Int
)
invoke
Link copied to clipboard
open
operator
fun
invoke
(
funcName
:
String
,
vararg
params
:
Any
?
)
:
Any
?
invoke
Indirect
Link copied to clipboard
open
fun
invokeIndirect
(
index
:
Int
,
vararg
params
:
Any
?
)
:
Any
?
read
Bytes
Link copied to clipboard
fun
readBytes
(
ptr
:
Int
,
out
:
ByteArray
)
:
ByteArray
fun
readBytes
(
ptr
:
Int
,
size
:
Int
)
:
ByteArray
read
String
Link copied to clipboard
fun
readString
(
ptr
:
Int
)
:
String
read
Stringz
Link copied to clipboard
fun
readStringz
(
ptr
:
Int
)
:
String
read
Stringz16
Link copied to clipboard
fun
readStringz16
(
ptr
:
Int
)
:
String
register
Link copied to clipboard
open
fun
register
(
moduleName
:
String
,
name
:
String
,
func
:
WasmRuntime
.
(
Array
<
Any
?
>
)
->
Any
?
)
stack
Alloc
Link copied to clipboard
fun
stackAlloc
(
size
:
Int
)
:
Int
stack
Alloc
And
Write
Link copied to clipboard
fun
stackAllocAndWrite
(
data
:
ByteArray
)
:
Int
stack
Restore
Link copied to clipboard
fun
stackRestore
(
stack
:
Int
)
stack
Save
Link copied to clipboard
fun
stackSave
(
)
:
Int
strlen
Link copied to clipboard
fun
strlen
(
ptr
:
Int
)
:
Int
strlen16
Link copied to clipboard
fun
strlen16
(
ptr
:
Int
)
:
Int
write
Bytes
Link copied to clipboard
fun
writeBytes
(
ptr
:
Int
,
data
:
ByteArray
)