aboutsummaryrefslogtreecommitdiff
path: root/src/Compilation.zig
diff options
context:
space:
mode:
authorJacob Young <jacobly0@users.noreply.github.com>2024-06-15 16:18:41 -0400
committerJacob Young <jacobly0@users.noreply.github.com>2024-07-07 22:59:52 -0400
commitcda716ecc43929fd1c2c9679335b8b22f1b67d1a (patch)
tree43161efad1af25784f1ac0933a3a4a94352ef6d6 /src/Compilation.zig
parentca02266157ee72e41068672c8ca6f928fcbf6fdf (diff)
downloadzig-cda716ecc43929fd1c2c9679335b8b22f1b67d1a.tar.gz
zig-cda716ecc43929fd1c2c9679335b8b22f1b67d1a.zip
InternPool: implement thread-safe hash map
Diffstat (limited to 'src/Compilation.zig')
-rw-r--r--src/Compilation.zig4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Compilation.zig b/src/Compilation.zig
index 1f4c425bc5..7e10febf0e 100644
--- a/src/Compilation.zig
+++ b/src/Compilation.zig
@@ -1397,7 +1397,7 @@ pub fn create(gpa: Allocator, arena: Allocator, options: CreateOptions) !*Compil
.error_limit = error_limit,
.llvm_object = null,
};
- try zcu.init();
+ try zcu.init(options.thread_pool.getIdCount());
break :blk zcu;
} else blk: {
if (options.emit_h != null) return error.NoZigModuleForCHeader;
@@ -2156,7 +2156,7 @@ pub fn update(comp: *Compilation, main_progress_node: std.Progress.Node) !void {
if (build_options.enable_debug_extensions and comp.verbose_generic_instances) {
std.debug.print("generic instances for '{s}:0x{x}':\n", .{
comp.root_name,
- @as(usize, @intFromPtr(zcu)),
+ @intFromPtr(zcu),
});
zcu.intern_pool.dumpGenericInstances(gpa);
}