This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(module | |
(type $t1 (func (param i32))) | |
(type $t2 (func (param i32 i32 i32) (result i32))) | |
(type $t3 (func (param i32) (result i32))) | |
(type $t4 (func (param i32 i32) (result i32))) | |
(func $putchar (import "env" "putchar") (type $t1)) | |
(func $printf (import "env" "printf") (type $t4)) | |
(func $sys_open (import "env" "sys_open") (type $t2)) | |
(func $sys_read (import "env" "sys_read") (type $t2)) | |
(func $sys_close (import "env" "sys_close") (type $t3)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from ctypes import cdll, c_int, c_uint, c_void_p, CFUNCTYPE | |
# Load library and get library | |
lib = cdll.LoadLibrary('./libwasmer.so') | |
# Get compile function | |
compile = lib.compile | |
compile.restype = c_void_p # vmctx_addr | |
# NOTE: Ideally we will pass import objects |
- __syscall1 - exit
This file has been truncated, but you can view the full file.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
|=== <Program> ===| | |
#__crystal_get_exception(Pointer(LibUnwind::Exception)) | |
#__crystal_malloc(UInt32) | |
#__crystal_malloc_atomic(UInt32) | |
#__crystal_personality(Int32, LibUnwind::Action, UInt64, Pointer(LibUnwind::Exception), Pointer(Void)) | |
#__crystal_raise(Pointer(LibUnwind::Exception)) | |
#__crystal_raise_string(Pointer(UInt8)) | |
#__crystal_realloc(Pointer(Void), UInt32) | |
#__crystal_sigfault_handler(Int32, Pointer(Void)) | |
#_fiber_get_stack_top() |
NewerOlder