jasonmolenda added a comment. In D76758#1944612 <https://reviews.llvm.org/D76758#1944612>, @clayborg wrote:
> So I know the mach-o symbol table parsing code is a mess already, but it > seems like this patch can be simpler if we make a std::set<lldb:addr_t> at > the top of ObjectFileMachO::ParseSymtab() and every time we add a symbol that > has a valid address value, add the file addr to this set. This will avoid the > need to do any sorting. This std::set can be used to not add > LC_FUNCTION_START entries that already have a symbol at the address, and it > can be used to only add TrieEntry values that have symbols. Thoughts? That's a solid idea, let me try rewriting for that. LC_FUNCTION_STARTS already has a 'done' bool with each one to indicate whether it should be added to the symtab at the end. & yeah, I should have just added a new flag to indicate that the thing had already been seen -- for the exported symbols from the trie I wasn't use flags at all so I just clobbered it, but that's not a very nice way to do it. Let me try doing the std::set thing I think that'll remove a bunch of code across the function. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D76758/new/ https://reviews.llvm.org/D76758 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits