authorgravatar for kubkon@jakubkonka.comJakub Konka <kubkon@jakubkonka.com> 2023-10-16 19:32:34+02:00
committergravatar for kubkon@jakubkonka.comJakub Konka <kubkon@jakubkonka.com> 2023-10-16 19:33:06+02:00
loge89155b565885d8fb0aca3d9843fba914f43e7d9
tree4decea359c4ed0e2b6570d0c2351fba5ad11a116
parentee1c3c70580bc8d0259a495cf67c3090196983b5

elf: refactor logs


2 files changed, 1 insertions(+), 7 deletions(-)

src/link/Elf.zig-6
...@@ -1627,12 +1627,6 @@ pub fn flushModule(self: *Elf, comp: *Compilation, prog_node: *std.Progress.Node...@@ -1627,12 +1627,6 @@ pub fn flushModule(self: *Elf, comp: *Compilation, prog_node: *std.Progress.Node
1627 try self.writeHeader();1627 try self.writeHeader();
1628 }1628 }
16291629
1630 // Dump the state for easy debugging.
1631 // State can be dumped via `--debug-log link_state`.
1632 if (build_options.enable_logging) {
1633 state_log.debug("{}", .{self.dumpState()});
1634 }
1635
1636 // The point of flush() is to commit changes, so in theory, nothing should1630 // The point of flush() is to commit changes, so in theory, nothing should
1637 // be dirty after this. However, it is possible for some things to remain1631 // be dirty after this. However, it is possible for some things to remain
1638 // dirty because they fail to be written in the event of compile errors,1632 // dirty because they fail to be written in the event of compile errors,
src/link/Elf/Atom.zig+1-1
...@@ -757,7 +757,7 @@ pub fn resolveRelocsAlloc(self: Atom, elf_file: *Elf, code: []u8) !void {...@@ -757,7 +757,7 @@ pub fn resolveRelocsAlloc(self: Atom, elf_file: *Elf, code: []u8) !void {
757 // Address of the dynamic thread pointer.757 // Address of the dynamic thread pointer.
758 const DTP = @as(i64, @intCast(elf_file.dtpAddress()));758 const DTP = @as(i64, @intCast(elf_file.dtpAddress()));
759759
760 relocs_log.debug(" {s}: {x}: [{x} => {x}] G({x}) ZG({x}) ({s})\n", .{760 relocs_log.debug(" {s}: {x}: [{x} => {x}] G({x}) ZG({x}) ({s})", .{
761 fmtRelocType(r_type),761 fmtRelocType(r_type),
762 r_offset,762 r_offset,
763 P,763 P,