diff options
| -rw-r--r-- | compiler/standardClient.ey | 11 | ||||
| -rw-r--r-- | elymas/lib/sys/so.ey | 11 |
2 files changed, 18 insertions, 4 deletions
diff --git a/compiler/standardClient.ey b/compiler/standardClient.ey index 01e894f..3b7828f 100644 --- a/compiler/standardClient.ey +++ b/compiler/standardClient.ey @@ -1084,8 +1084,15 @@ section .dataOffset fileOffset sub str .alloc out .writeall section .dataOffset section .dataSize add =fileOffset - out .fd section .dataBase section .dataSize 0 0 0 WRITE sys .asm .syscall -- - section .dataSize neq { "write failed" die } rep + 2000000000 ==:BLOCKSIZE + 0 section .dataSize BLOCKSIZE div 1 add range { ==block + section .dataBase block BLOCKSIZE mul add ==dataBase + block section .dataSize BLOCKSIZE div eq + section .dataSize block BLOCKSIZE mul sub BLOCKSIZE ? ==dataSize + + out .fd dataBase dataSize 0 0 0 WRITE sys .asm .syscall -- + dataSize neq { "write failed" die } rep + } each } each out .close diff --git a/elymas/lib/sys/so.ey b/elymas/lib/sys/so.ey index 029d446..da8c00a 100644 --- a/elymas/lib/sys/so.ey +++ b/elymas/lib/sys/so.ey @@ -1150,8 +1150,15 @@ section .dataOffset fileOffset sub str .alloc out .writeall section .dataOffset section .dataSize add =fileOffset - out .fd section .dataBase section .dataSize 0 0 0 WRITE sys .asm .syscall -- - section .dataSize neq { "write failed" die } rep + 2000000000 ==:BLOCKSIZE + 0 section .dataSize BLOCKSIZE div 1 add range { ==block + section .dataBase block BLOCKSIZE mul add ==dataBase + block section .dataSize BLOCKSIZE div eq + section .dataSize block BLOCKSIZE mul sub BLOCKSIZE ? ==dataSize + + out .fd dataBase dataSize 0 0 0 WRITE sys .asm .syscall -- + dataSize neq { "write failed" die } rep + } each } each out .close |
