summaryrefslogtreecommitdiffhomepage
path: root/dev/SCIKit
diff options
context:
space:
mode:
authorAmlal <amlal.elmahrouss@icloud.com>2024-10-30 08:57:05 +0100
committerAmlal <amlal.elmahrouss@icloud.com>2024-10-30 08:57:05 +0100
commit96a4f30672702e34afea4014487936fccb850779 (patch)
tree7e3e39c63335158143450bf6bcaf9fae20b6cbfd /dev/SCIKit
parent8600ffcc1ddfc861e761baf2682490061a55cca8 (diff)
META: Daily bump.
Signed-off-by: Amlal <amlal.elmahrouss@icloud.com>
Diffstat (limited to 'dev/SCIKit')
-rw-r--r--dev/SCIKit/LPC.h3
-rw-r--r--dev/SCIKit/build.json2
-rw-r--r--dev/SCIKit/src/Syscall.asm48
3 files changed, 52 insertions, 1 deletions
diff --git a/dev/SCIKit/LPC.h b/dev/SCIKit/LPC.h
index e602156d..832deb99 100644
--- a/dev/SCIKit/LPC.h
+++ b/dev/SCIKit/LPC.h
@@ -6,6 +6,9 @@
#pragma once
+/// @file LPC.h
+/// @brief Local Process Codes.
+///
#define ErrLocalIsOk() (kLastError == kErrorSuccess)
#define ErrLocalFailed() (kLastError != kErrorSuccess)
#define ErrLocal() (kLastError)
diff --git a/dev/SCIKit/build.json b/dev/SCIKit/build.json
index 104be044..8f2af775 100644
--- a/dev/SCIKit/build.json
+++ b/dev/SCIKit/build.json
@@ -2,7 +2,7 @@
"compiler_path": "x86_64-w64-mingw32-g++",
"compiler_std": "c++20",
"headers_path": ["../"],
- "sources_path": ["src/*.cc"],
+ "sources_path": ["src/*.cc", "src/*.obj"],
"output_name": "sci.dll",
"compiler_flags": [
"-fPIC",
diff --git a/dev/SCIKit/src/Syscall.asm b/dev/SCIKit/src/Syscall.asm
new file mode 100644
index 00000000..d1928191
--- /dev/null
+++ b/dev/SCIKit/src/Syscall.asm
@@ -0,0 +1,48 @@
+;; /*
+;; * ========================================================
+;; *
+;; * ZKA
+;; * Copyright EL Mahrouss Logic., all rights reserved.
+;; *
+;; * ========================================================
+;; */
+
+[bits 64]
+
+global sci_syscall_1
+global sci_syscall_2
+global sci_syscall_3
+global sci_syscall_4
+
+sci_syscall_1:
+ mov r8, rcx
+ syscall
+ ret
+
+sci_syscall_2:
+ mov r8, rcx
+ mov r9, rdx
+ syscall
+ ret
+
+sci_syscall_3:
+ mov rbx, r8
+
+ mov r8, rcx
+ mov r9, rdx
+ mov r10, rbx
+
+ syscall
+ ret
+
+sci_syscall_4:
+ mov rbx, r8
+ mov rax, r9
+
+ mov r8, rcx
+ mov r9, rdx
+ mov r10, rbx
+ mov r11, rax
+
+ syscall
+ ret