diff options
| author | Jacob Young <jacobly0@users.noreply.github.com> | 2024-07-16 14:49:49 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-07-16 14:49:49 -0400 |
| commit | 88bb0fd288acb6a20abed57cdf459cc4fc788b89 (patch) | |
| tree | 4a488eb0c9ef76f63d13d12de1649ddab9b8caac /src/main.zig | |
| parent | d8f81372f148ad2ee5aab12cc7ea55562764b3e7 (diff) | |
| parent | 00fdbf05f39931d1f6c5808e8da4afca85357214 (diff) | |
| download | zig-88bb0fd288acb6a20abed57cdf459cc4fc788b89.tar.gz zig-88bb0fd288acb6a20abed57cdf459cc4fc788b89.zip | |
Merge pull request #20632 from jacobly0/codegen-thread
InternPool: enable separate codegen/linking thread
Diffstat (limited to 'src/main.zig')
| -rw-r--r-- | src/main.zig | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main.zig b/src/main.zig index a5b315c2bb..9b14170d78 100644 --- a/src/main.zig +++ b/src/main.zig @@ -3110,7 +3110,7 @@ fn buildOutputType( var thread_pool: ThreadPool = undefined; try thread_pool.init(.{ .allocator = gpa, - .n_jobs = @min(@max(n_jobs orelse std.Thread.getCpuCount() catch 1, 1), std.math.maxInt(u8)), + .n_jobs = @min(@max(n_jobs orelse std.Thread.getCpuCount() catch 1, 1), std.math.maxInt(Zcu.PerThread.IdBacking)), .track_ids = true, }); defer thread_pool.deinit(); @@ -4964,7 +4964,7 @@ fn cmdBuild(gpa: Allocator, arena: Allocator, args: []const []const u8) !void { var thread_pool: ThreadPool = undefined; try thread_pool.init(.{ .allocator = gpa, - .n_jobs = @min(@max(n_jobs orelse std.Thread.getCpuCount() catch 1, 1), std.math.maxInt(u8)), + .n_jobs = @min(@max(n_jobs orelse std.Thread.getCpuCount() catch 1, 1), std.math.maxInt(Zcu.PerThread.IdBacking)), .track_ids = true, }); defer thread_pool.deinit(); @@ -5402,7 +5402,7 @@ fn jitCmd( var thread_pool: ThreadPool = undefined; try thread_pool.init(.{ .allocator = gpa, - .n_jobs = @min(@max(std.Thread.getCpuCount() catch 1, 1), std.math.maxInt(u8)), + .n_jobs = @min(@max(std.Thread.getCpuCount() catch 1, 1), std.math.maxInt(Zcu.PerThread.IdBacking)), .track_ids = true, }); defer thread_pool.deinit(); |
