llvm-project/lldb/source/Breakpoint
Greg Clayton 6234a5c863 Centralize the way symbol and functions are looked up by making a Module::LookupInfo class that does all of the heavy lifting.
Background: symbols and functions can be looked up by full mangled name and by basename. SymbolFile and ObjectFile are expected to be able to do the lookups based on full mangled name or by basename, so when the user types something that is incomplete, we must be able to look it up efficiently. For example the user types "a:🅱️:c" as a symbol to set a breakpoint on, we will break this down into a 'lookup "c"' and then weed out N matches down to just the ones that match "a:🅱️:c". Previously this was done manaully in many functions by calling Module::PrepareForFunctionNameLookup(...) and then doing the lookup and manually pruning the results down afterward with duplicated code. Now all places use Module::LookupInfo to do the work in one place.

This allowed me to fix the name lookups to look for "func" with eFunctionNameTypeFull as the "name_type_mask", and correctly weed the results:

"func", "func()", "func(int)", "a::func()", "b::func()", and "a:🅱️:func()" down to just "func", "func()", "func(int)". Previously we would have set 6 breakpoints, now we correctly set just 3. This also extends to the expression parser when it looks up names for functions it needs to not get multiple results so we can call the correct function.

<rdar://problem/24599697> 

llvm-svn: 275281
2016-07-13 17:12:24 +00:00
..
Breakpoint.cpp second pass over removal of Mutex and Condition 2016-05-19 05:13:57 +00:00
BreakpointID.cpp Fix Clang-tidy modernize-use-nullptr warnings in source/Breakpoint; other minor fixes. 2015-10-30 18:50:12 +00:00
BreakpointIDList.cpp Fix Clang-tidy modernize-use-nullptr warnings in source/Breakpoint; other minor fixes. 2015-10-30 18:50:12 +00:00
BreakpointList.cpp second pass over removal of Mutex and Condition 2016-05-19 05:13:57 +00:00
BreakpointLocation.cpp second pass over removal of Mutex and Condition 2016-05-19 05:13:57 +00:00
BreakpointLocationCollection.cpp Lock the access to the BreakpointLocationCollection. 2016-05-26 23:55:04 +00:00
BreakpointLocationList.cpp remove use of Mutex in favour of std::{,recursive_}mutex 2016-05-18 01:59:10 +00:00
BreakpointOptions.cpp Fix Clang-tidy modernize-use-nullptr warnings in source/Breakpoint; other minor fixes. 2015-10-30 18:50:12 +00:00
BreakpointResolver.cpp Keep original source path and mapped path in LineEntry 2016-05-11 22:46:53 +00:00
BreakpointResolverAddress.cpp Add an "offset" option to "break set -n" and "break set -f -l". 2016-03-09 18:59:13 +00:00
BreakpointResolverFileLine.cpp Add an "offset" option to "break set -n" and "break set -f -l". 2016-03-09 18:59:13 +00:00
BreakpointResolverFileRegex.cpp Add the ability to limit "source regexp" breakpoints to a particular function 2016-04-28 01:40:57 +00:00
BreakpointResolverName.cpp Centralize the way symbol and functions are looked up by making a Module::LookupInfo class that does all of the heavy lifting. 2016-07-13 17:12:24 +00:00
BreakpointSite.cpp remove use of Mutex in favour of std::{,recursive_}mutex 2016-05-18 01:59:10 +00:00
BreakpointSiteList.cpp remove use of Mutex in favour of std::{,recursive_}mutex 2016-05-18 01:59:10 +00:00
CMakeLists.txt [cmake] Remove LLVM_NO_RTTI. 2015-09-03 08:46:55 +00:00
Stoppoint.cpp
StoppointCallbackContext.cpp Fix Clang-tidy modernize-use-nullptr warnings in source/Breakpoint; other minor fixes. 2015-10-30 18:50:12 +00:00
StoppointLocation.cpp Make sure that when a breakpoint is hit but its condition is not met, 2015-01-15 01:41:04 +00:00
Watchpoint.cpp [LLDB][Watchpoint] Change ignore_count condition location to fix watchpoint ignore feature for architectures with watchpoint_exceptions_received=before 2015-11-03 09:04:33 +00:00
WatchpointList.cpp second pass over removal of Mutex and Condition 2016-05-19 05:13:57 +00:00
WatchpointOptions.cpp Fix Clang-tidy modernize-use-nullptr warnings in source/Breakpoint; other minor fixes. 2015-10-30 18:50:12 +00:00