Working on new type system, planning out debugmanager

This commit is contained in:
2023-09-04 12:03:00 -04:00
parent a660b63581
commit 5f5723e936
11 changed files with 98 additions and 87 deletions
+3 -1
View File
@@ -35,6 +35,7 @@ end
function multi:newSystemThreadedQueue(name)
local c = {}
c.Type = multi.registerType("s_queue")
function c:push(v)
table.insert(self,v)
end
@@ -64,6 +65,7 @@ end
function multi:newSystemThreadedTable(name)
local c = {}
c.Type = multi.registerType("s_table")
function c:init()
return self
end
@@ -88,7 +90,7 @@ function multi:newSystemThreadedJobQueue(n)
c.cores = n or THREAD.getCores()
c.registerQueue = {}
c.Type = multi.SJOBQUEUE
c.Type = multi.registerType("s_jobqueue")
c.funcs = multi:newSystemThreadedTable("__JobQueue_"..jqc.."_table")
c.queue = multi:newSystemThreadedQueue("__JobQueue_"..jqc.."_queue")
c.queueReturn = multi:newSystemThreadedQueue("__JobQueue_"..jqc.."_queueReturn")
+2 -1
View File
@@ -91,6 +91,7 @@ function multi:newSystemThread(name, func, ...)
local GLOBAL, THREAD = activator.init(thread, env)
local th = thread:newISOThread(name, func, env, ...)
th.Type = multi.registerType("s_thread", "pseudoThreads")
id = id + 1
@@ -104,7 +105,7 @@ THREAD.newSystemThread = multi.newSystemThread
function THREAD:newFunction(func,holdme)
return thread:newFunctionBase(function(...)
return multi:newSystemThread("TempSystemThread",func,...)
end,holdme)()
end, holdme, multi.registerType("s_function", "pseudoFunctions"))()
end
multi.print("Integrated Pesudo Threading!")