| ... | @@ -91,7 +91,12 @@ fn mark(roots: []*Atom, objects: []const File.Index, macho_file: *MachO) void { | ... | @@ -91,7 +91,12 @@ fn mark(roots: []*Atom, objects: []const File.Index, macho_file: *MachO) void { |
| 91 | for (macho_file.getFile(index).?.getAtoms()) |atom_index| { | 91 | for (macho_file.getFile(index).?.getAtoms()) |atom_index| { |
| 92 | const atom = macho_file.getAtom(atom_index).?; | 92 | const atom = macho_file.getAtom(atom_index).?; |
| 93 | const isec = atom.getInputSection(macho_file); | 93 | const isec = atom.getInputSection(macho_file); |
| 94 | if (isec.isDontDeadStripIfReferencesLive() and !atom.flags.alive and refersLive(atom, macho_file)) { | 94 | if (isec.isDontDeadStripIfReferencesLive() and |
| | 95 | !(mem.eql(u8, isec.sectName(), "__eh_frame") or |
| | 96 | mem.eql(u8, isec.sectName(), "__compact_unwind") or |
| | 97 | isec.attrs() & macho.S_ATTR_DEBUG != 0) and |
| | 98 | !atom.flags.alive and refersLive(atom, macho_file)) |
| | 99 | { |
| 95 | markLive(atom, macho_file); | 100 | markLive(atom, macho_file); |
| 96 | loop = true; | 101 | loop = true; |
| 97 | } | 102 | } |