3 ms·
As someone who’s built my company’s mobile crash reporting solution, I have a guess why they might do this. It’s is extremely difficult to diagnose Android nat
by js2 7y ago
As someone who’s built my company’s mobile crash reporting solution, I have a guess why they might do this.
It’s is extremely difficult to diagnose Android native code crashes. Unlike iOS where it is both straightforward to unwind on the phone, and where Apple makes the iOS system symbols available for symbolizing system frames in a stack trace, neither of these things are true on Android.
My first approach for my company’s Android crash manager SDK was to use Google Breakpad. This works by capturing a snapshot of stack memory at the time of the crash. Unwinding then occurs on a backend server. But to unwind successfully, absent a frame pointer register, you need unwind info to provide to the unwinder. This simply isn’t available except for Nexus devices for which you can download the system images from Google. And even on devices where the code was compiled with a frame pointer, you still need symbols so you know what each frame’s function was.
Another approach is to unwind on the device. In my experience, using libunwind, this is successful about 50% of the time. It also risks hanging the app, which looks even worse to the user than just crashing.
Years ago, I briefly considered having our crash SDK, optionally and with user consent, extract the symbols and unwind data from the libraries on the device and upload them to our backend. I dismissed it as too expensive to do on a user’s phone.
Instead, we crowd source as much as we can from our employee phones.
Android native code crashes remain a bear to diagnose. Especially annoying since Android itself collects a ton of diagnostic data about your app when it crashes - it just doesn’t make it easily, or in some cases at all, accessible to the app itself.
- deleted 7y ago[deleted]
- lugg 7y agoThis is clearly not for crash reporting. They're sucking up libs to figure out what apps their users use. Could be a few reasons, could be boring metrics, could be anticompetitive identification of acquisition targets, could be oppo research, could be user profiling. None of these things I'm ok with Facebook getting off my phone.
- Shish2k 7y ago> They're sucking up libs to figure out what apps their users use. Hypothesis 1, debugging: requires full copies of system libraries Hypothesis 2, fingerprinting: requires hashes of application libraries Evidence: full copies of system libraries are being uploaded How are you using that evidence to be so confident in hypothesis 2 and confidently against hypothesis 1?
- number6 7y agoHypothesis 3: they do both
- deleted 7y ago[deleted]
- cjhopman 7y agoIt sounds like you don't understand what the term "system libraries" means. It's impossible to tell what apps people are using by uploading system libraries. You could probably tell what type of phone they are using by doing it, but that would be dumb since Android already tells you what kind of phone it is.