This is an archive of the discontinued LLVM Phabricator instance.

[lldb] [Process/FreeBSDRemote] Remove thread name caching
ClosedPublic

Authored by mgorny on Nov 5 2020, 10:02 AM.

Details

Summary

Remove the thread name caching code. It does not handle the possibility
of thread name changing between requests, therefore breaking
TestGdbRemoteThreadName. While technically we could cache the results
and reset the cache on resuming process, the gain from doing that
does not seem worth the effort.

Diff Detail

Event Timeline

mgorny created this revision.Nov 5 2020, 10:02 AM

Does Linux fetch each time also?
I agree it's probably not worth the effort.

Does Linux fetch each time also?
I agree it's probably not worth the effort.

Yes. However, their logic is simpler (it boils down to opening a dedicated file in procfs (i.e. they don't have to iterate over all threads). Nevertheless, I don't think this is called frequently enough to justify optimization at this point.

krytarowski accepted this revision.Nov 5 2020, 11:43 AM
This revision is now accepted and ready to land.Nov 5 2020, 11:43 AM
This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptNov 5 2020, 11:46 AM