[PATCH] [compiler-rt] atos symbolizer for OS X

Kuba Brecka kuba.brecka at gmail.com
Tue Dec 30 18:28:15 PST 2014


Thanks for the review, I'll extract a NFC refactoring patch, but first I'd like to ask you to clarify what you suggest in the following comments:

> I don't like that in some concrete classes (e.g. LibbacktraceSymbolizer) require that certain fields of "stack" structure are filled by the caller.


I see. It's meant as both an input and output, and since it's created at a single place (in `POSIXSymbolizer::SymbolizePC`), it's always pre-filled with the address, module name and module offset. I did that to avoid passing these 3 values to all the function calls. Any better suggestions what the interface should look like?

> Wait, LibbacktraceSymbolizer and DladdrSymbolizer also implement SymbolizerInterface, why don't we return them here?


I wanted to keep the current behavior, which is a weird chain: On every symbolication request, LibbacktraceSymbolizer is called first, and if it fails, we try the "regular" symbolizer, which is either internal_symbolizer or external_symbolizer. I also wanted to add the DladdrSymbolizer into that chain, so it's only used when a "regular" symbolizer failed. The reason is that we only realize that we cannot spawn an external symbolizer after we try to at least once.

You're right that the change to LibbacktraceSymbolizer was completely broken, sorry was that.


http://reviews.llvm.org/D6588

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/






More information about the llvm-commits mailing list