1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

builtin: use dlmalloc for -freestanding (#13054)

This commit is contained in:
playX
2022-01-06 15:10:37 +03:00
committed by GitHub
parent fb66ec7cfb
commit ec91de3504
12 changed files with 284 additions and 108 deletions

View File

@ -262,6 +262,13 @@ fn sys_munmap(addr voidptr, len u64) Errno {
return Errno(-sys_call2(11, u64(addr), len))
}
// 25 sys_mremap
fn sys_mremap(old_addr voidptr, old_len u64, new_len u64, flags u64) (&byte, Errno) {
rc := sys_call4(25, u64(old_addr), old_len, new_len, flags)
a, e := split_int_errno(rc)
return &byte(a), e
}
// 22 sys_pipe
fn sys_pipe(filedes &int) Errno {
return Errno(sys_call1(22, u64(filedes)))