Job system priorities, async waits, parallel map/queue

Major refactor:
- Add job priority tiers and async wait APIs to IJobScheduler
- Implement priority-based job queues and scheduling logic
- Introduce UnsafeParallelHashMap and refactor UnsafeParallelQueue
- Refactor UnsafeSlotMap to chunked storage for scalability
- Update SlotMap/ConcurrentSlotMap for consistency and perf
- Add new benchmarks and unit tests for parallel collections
- Misc: add MemoryUtility.AlignUp, version bumps, test improvements, bug fixes
This commit is contained in:
2026-04-18 11:26:08 +09:00
parent d5616daa05
commit 13802ca6c8
22 changed files with 1459 additions and 267 deletions

View File

@@ -71,6 +71,23 @@ public class TestUnsafeSlotMap
}
}
[TestMethod]
public void ReferenceValidAfterResize()
{
var id = _slotMap.Add(10, out var gen);
ref var value = ref _slotMap.GetElementReferenceAt(id, gen, out _);
Assert.AreEqual(10, value);
// Force resize
for (var i = 0; i < 20; i++)
{
_slotMap.Add(i, out _);
}
Assert.AreEqual(10, value);
}
[TestMethod]
public void Clear()
{