Files
Misaki.HighPerformance/Misaki.HighPerformance.Jobs/JobExecutionContext.cs
Misaki a704cb19ec refactor(jobs, allocator): optimize queues & dependencies
Major refactor of job system and memory allocator:
- Replaced threadIndex with preferLocal for scheduling
- Switched local queues to SPMCQueue for better performance
- Introduced lock-free JobEdge pool for dependencies
- Removed remainingBatches; use ref counting for completion
- Updated all scheduling APIs and tests to new model
- Optimized FreeList struct sizes and block management
- Added allocation benchmarks
- Disabled OwnershipTransferAnalyzer temporarily
- Bumped assembly versions
2026-04-22 13:51:14 +09:00

36 lines
755 B
C#

namespace Misaki.HighPerformance.Jobs;
public readonly ref struct JobExecutionContext
{
/// <summary>
/// Gets the 0-based index of the current thread executing the job.
/// </summary>
public int ThreadIndex
{
get; init;
}
/// <summary>
/// Gets the job scheduler that is responsible for managing the execution of jobs.
/// </summary>
public JobScheduler JobScheduler
{
get; init;
}
/// <summary>
/// Gets the state object for the job scheduler.
/// </summary>
public object? State
{
get; init;
}
/// <summary>
/// Gets the handle for the currently executing job.
/// </summary>
public JobHandle SelfHandle
{
get; init;
}
}