Unity’s C# job system is a powerful tool, but it can be difficult to understand how various jobs, their dependencies on each other, and the data they use all work together to accomplish a task. Today we’ll create a little tool that visualizes and generates job graphs so it’s much easier to understand them and easier to build larger, more powerful graphs.
Posts Tagged job
Unity 2018.3 brings us even more thread-safe APIs that we can call from the C# job system. Today we’ll look at a systematic way to find them all so we know what’s safe to use and what’s not.
Last week’s article introduced two new native collection types:
NativeLongPtr. These were useful for both
IJobParallelFor jobs, but performance was degraded in
IJobParallelFor. Today we’ll remedy that, explore some more aspects of Unity’s native collection and job systems, and learn more about CPU caches along the way.
Two weeks ago we tested the performance of the
await keywords plus the C#
Task system against Unity’s new C# jobs system. This tested the usual combination of
await with the
Task system, but didn’t test the
Task system directly against Unity’s C# jobs system. Today we’ll test that and, in so doing, see how to use the
Task system without the
Unity 2018.1 brought us two asynchronous code systems. First, there’s C# 5’s
await keywords in conjunction with the
Task<T> types. Second, there’s Unity’s own C# jobs system. There are many differences, but which is faster? Today’s article puts them to the test to find out!
Last time in the series we encountered and overcame a host of esoteric issues on our path to a better understanding of Unity’s native collection system. This week we’ll continue on that journey and grapple with even more challenges in this new, unexplored area of Unity.
Unity 2018.1 shipped with just one true native container:
NativeArray<T>. Now Unity 2018.2 has been released and there is still just the one native container. We’ve seen how to implement more, but never wrote much more than a proof of concept. Today we’ll begin implementing
NativeLinkedList<T> as an example of a native container for a very well known, simple data type. The result is available on GitHub for any project to use.
My Job System Tutorial listed many Unity APIs accessible from C# jobs, but the list was incomplete. Today I’ll add on to the list with some newly-released 2018.2 features as well as some powerful 2018.1 features that were left off of the last article. Many of these aren’t documented in Unity’s release notes. Read on to learn more about what you can do with C# jobs!