Skip to content
/ luau-go Public

Execute the functions in a separate thread, threads are pooled and reused.

License

Notifications You must be signed in to change notification settings

jiwonz/luau-go

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

luau-go

Executes the given function in a separate thread, threads are pooled and reused.

Tip

It runs faster than task.spawn if the thread doesn't yield (The more non-yielding threads you can make go, the more threads you can reuse.)

Features

  • Very small and simple module, useful for optimizing task.spawn by reusing threads.
  • Original: util.luau/threadpool
  • Supports executing functions in separate threads and reusing threads
  • Supports various lua environments (luau, lune, and roblox)

Installation

From pesde

pesde add jiwonz/go

Example Usage

local t: thread = go(function()
	...
end)

About

Execute the functions in a separate thread, threads are pooled and reused.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages