HomePhabricator

DebugInfo/Symbolize: Don't differentiate function/data symbolization

Authored by MaskRay on Feb 11 2021, 7:22 PM.

Description

DebugInfo/Symbolize: Don't differentiate function/data symbolization

Before d08bd13ac8a560c4645e17e192ca07e1bdcd2895, only SymbolRef::ST_Function
symbols were used for .symtab symbolization. That commit added a "DATA" mode
to llvm-symbolizer which used SymbolRef::ST_Data symbols for symbolization.

Since function and data symbols have different addresses, we don't need to
differentiate the two modes. This patches unifies the two modes to simplify
code.

"DATA" is used by compiler-rt/lib/sanitizer_common/sanitizer_symbolizer_libcdep.cpp.
check-hwasan and check-tsan have runtime tests.

Differential Revision: https://reviews.llvm.org/D96322