diff options
| author | Drahflow <drahflow@gmx.de> | 2013-01-03 22:11:37 +0100 |
|---|---|---|
| committer | Drahflow <drahflow@gmx.de> | 2013-01-03 22:11:37 +0100 |
| commit | 19d573cf7c6dd729289ef5151f15db51bcc79d91 (patch) | |
| tree | 288980504ab3721cfa7fd0aea59514957c17b45d /ACME-Bare-Metal/Metal.xs | |
| parent | d7d307dc6563fe27bf43cab1e83ac21204fea6c6 (diff) | |
Compiler can now push ints and strings
Diffstat (limited to 'ACME-Bare-Metal/Metal.xs')
| -rw-r--r-- | ACME-Bare-Metal/Metal.xs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/ACME-Bare-Metal/Metal.xs b/ACME-Bare-Metal/Metal.xs index cb7e5a0..a4e16d3 100644 --- a/ACME-Bare-Metal/Metal.xs +++ b/ACME-Bare-Metal/Metal.xs @@ -17,6 +17,16 @@ allocate(length) OUTPUT: RETVAL +void * +allocateAt(length, addr) + int length + void *addr + CODE: + RETVAL = mmap(addr, length, PROT_EXEC | PROT_READ | PROT_WRITE, + MAP_PRIVATE | MAP_ANONYMOUS | MAP_FIXED, -1, 0); + OUTPUT: + RETVAL + void deallocate(block, length) void *block |
