Bug 12731 - File / line numbers in crash reports are wrong
Summary: File / line numbers in crash reports are wrong
Alias: None
Product: iOS
Classification: Xamarin
Component: XI runtime ()
Version: 6.3.x
Hardware: PC Mac OS
: --- normal
Target Milestone: Untriaged
Assignee: Zoltan Varga
Depends on:
Reported: 2013-06-18 07:01 UTC by Rolf Bjarne Kvinge [MSFT]
Modified: 2013-06-21 19:55 UTC (History)
2 users (show)

Is this bug a regression?: ---
Last known good build:

crashtest.zip (3.04 KB, application/zip)
2013-06-18 07:04 UTC, Rolf Bjarne Kvinge [MSFT]
debugbuild.crash (22.44 KB, text/plain)
2013-06-18 07:05 UTC, Rolf Bjarne Kvinge [MSFT]
releasebuild.crash (20.61 KB, text/plain)
2013-06-18 07:05 UTC, Rolf Bjarne Kvinge [MSFT]

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description Rolf Bjarne Kvinge [MSFT] 2013-06-18 07:01:50 UTC
If I run the attached test case, I get weird file/line number information in crash reports:

7   crashtest  0x00002490 wrapper_managed_to_native_crashtest_AppDelegate_strlen_intptr (/<unknown>:42)
28  crashtest  0x00002394 crashtest_AppDelegate_Main_string__ (/<unknown>:41)

MonoTouch: (a5376d5)

This used to work better, so it looks like a regression of some sort.
Comment 1 Rolf Bjarne Kvinge [MSFT] 2013-06-18 07:04:42 UTC
Created attachment 4140 [details]
Comment 2 Rolf Bjarne Kvinge [MSFT] 2013-06-18 07:05:38 UTC
Created attachment 4141 [details]
Comment 3 Rolf Bjarne Kvinge [MSFT] 2013-06-18 07:05:53 UTC
Created attachment 4142 [details]
Comment 4 Zoltan Varga 2013-06-18 13:23:55 UTC
The gdb stack trace looks better:

#0  0x3b6cbb54 in strlen ()
#1  0x00002574 in (wrapper managed-to-native) crashtest.AppDelegate:strlen (param0=0) at AppDelegate.cs:42
#2  0x0000235c in crashtest.AppDelegate:CrashMe (this=@0x12715f8) at AppDelegate.cs:33
#3  0x0000221c in crashtest.AppDelegate:FinishedLaunching (this=@0xe58d0000, app=@0xe59d0000, options=@0xe3a01000) at AppDelegate.cs:22

It seems that ios uses a slightly different way to compute stack traces/line numbers.
Comment 5 Rolf Bjarne Kvinge [MSFT] 2013-06-20 09:19:40 UTC
fwiw this might be an interesting read: http://blog.testflightapp.com/post/11322114068/real-time-symbolication
Comment 6 Zoltan Varga 2013-06-21 19:55:26 UTC
Fixed in master.
Comment 7 Zoltan Varga 2013-06-21 19:55:37 UTC
-> fixed.