Commit Graph

5 Commits

Author SHA1 Message Date
Jason Molenda ebd01b0ae6 Guard against the case where the Write method is called with
an argument pointing into the middle of m_buffer and then
Write() calls GrowBuffer() to resize m_buffer, leaving 
the content argument pointing into deallocated memory.

Patch by Kate Stone.
<rdar://problem/20756722> 

llvm-svn: 236286
2015-04-30 23:42:56 +00:00
Kate Stone 641e9f8c69 Improvements to FastDemangler to correct parsing of <local-name> encodings for string literal and parameter/entity cases. Patch courtesy of slydiman.
llvm-svn: 223569
2014-12-06 01:42:41 +00:00
Jason Molenda 61e0a3ef1f Put #if 0 blocks around three sections of code that are intentionally
unreachable so we don't get warnings about them.

Completely initialize a structure instead of leaving some of its fields
potentially indeterminate (although in reality they would all be set 
before use -- but the compiler warning doesn't know that).

clang warning.

llvm-svn: 220017
2014-10-17 01:36:20 +00:00
Jason Molenda 026aa4962a Mechanical change to FastDemangle to make it closer to the lldb
coding conventions.  Lots of whitespace et al changes but no
content changes.

llvm-svn: 219856
2014-10-15 22:11:15 +00:00
Kate Stone e2b2186652 Dramatically improves C++ demangling performance by introducing a new implementation that is much faster than the existing demangler. While not yet complete, the new demangler will fail gracefully when it encounters symbols it isn’t prepared to deal with. In these cases LLDB will fall back to using the full demangler to prevent a loss in functionality. On sizable code bases the fast path succeeds 95% of the time, providing a significant net win.
The new implementation is located in source/Core/FastDemangle.cpp.  It’s fairly straightforward C code with a few basic C++ extensions.  It should compile with little or no change on a variety of platforms, but of course it is still only useful for symbols that comply with the Itanium ABI mangling spec (plus a few Clang extensions.)

<rdar://problem/15397553> <rdar://problem/15794867>

llvm-svn: 213671
2014-07-22 17:03:38 +00:00