Bug 42337 - OpenGL ES 2.0: ElementArrayBuffer+DrawElements = SIGSEGV crash
Summary: OpenGL ES 2.0: ElementArrayBuffer+DrawElements = SIGSEGV crash
Status: RESOLVED NORESPONSE
Alias: None
Product: Android
Classification: Xamarin
Component: General ()
Version: unspecified
Hardware: PC Windows
: --- normal
Target Milestone: ---
Assignee: Radek Doulik
URL:
Depends on:
Blocks:
 
Reported: 2016-07-03 16:41 UTC by Rishub
Modified: 2017-08-23 20:49 UTC (History)
4 users (show)

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

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:
Status:
RESOLVED NORESPONSE

Description Rishub 2016-07-03 16:41:06 UTC
Confirmation of this bug : https://forums.xamarin.com/discussion/41910/opengl-es-2-0-elementarraybuffer-drawelements-sigsegv-crash

I was able to reproduce it by altering the monodroid GLTriangle20-1.0 sample to use an element array buffer. The result is a crash on launch. 

07-03 12:21:46.528 E/mono-rt ( 7723): Attempting native Android stacktrace:
07-03 12:21:46.528 E/mono-rt ( 7723): 
07-03 12:21:46.534 E/mono-rt ( 7723):  at ???+1 [0x9e81e7d8]
07-03 12:21:46.571 E/mono-rt ( 7723): 
07-03 12:21:46.571 E/mono-rt ( 7723): =================================================================
07-03 12:21:46.571 E/mono-rt ( 7723): Got a SIGSEGV while executing native code. This usually indicates
07-03 12:21:46.571 E/mono-rt ( 7723): a fatal error in the mono runtime or one of the native libraries 
07-03 12:21:46.571 E/mono-rt ( 7723): used by your application.
07-03 12:21:46.571 E/mono-rt ( 7723): =================================================================
07-03 12:21:46.571 E/mono-rt ( 7723): 
07-03 12:21:46.571 F/libc    ( 7723): Fatal signal 11 (SIGSEGV), code 2, fault addr 0xbe203fd4 in tid 7723 (TreeGo.Droid)
07-03 12:21:47.096 W/Triange.sample( 7723): type=1701 audit(0.0:3404): auid=4294967295 uid=10193 gid=10193 ses=4294967295 subj=u:r:untrusted_app:s0 reason="memory violation" sig=11

Possible work around is to give an offset to GL.DrawElements, however you cannot use an EBO 

Code from the forum thread can be used to reproduce.
Comment 1 Rishub 2016-07-03 16:43:52 UTC
Sorry, correct stacktrace: 

07-03 12:21:46.528 E/mono-rt ( 7723): Attempting native Android stacktrace:
07-03 12:21:46.528 E/mono-rt ( 7723): 
07-03 12:21:46.534 E/mono-rt ( 7723):  at ???+1 [0x9e81e7d8]
07-03 12:21:46.571 E/mono-rt ( 7723): 
07-03 12:21:46.571 E/mono-rt ( 7723): =================================================================
07-03 12:21:46.571 E/mono-rt ( 7723): Got a SIGSEGV while executing native code. This usually indicates
07-03 12:21:46.571 E/mono-rt ( 7723): a fatal error in the mono runtime or one of the native libraries 
07-03 12:21:46.571 E/mono-rt ( 7723): used by your application.
07-03 12:21:46.571 E/mono-rt ( 7723): =================================================================
07-03 12:21:46.571 E/mono-rt ( 7723): 
07-03 12:21:46.571 F/libc    ( 7723): Fatal signal 11 (SIGSEGV), code 2, fault addr 0xbe203fd4 in tid 7723 (TreeGo.Droid)
07-03 12:21:47.096 W/TreeGo.Droid( 7723): type=1701 audit(0.0:3404): auid=4294967295 uid=10193 gid=10193 ses=4294967295 subj=u:r:untrusted_app:s0 reason="memory violation" sig=11

TreeGo.Droid is the renamed sample
Comment 2 John Miller [MSFT] 2017-06-30 14:29:47 UTC
Thank you for taking the time to submit the bug. We are unable to reproduce this issue. Please attach a reproduction to the bug by starting with a clean Xamarin.Android project and adding just the code necessary to demonstrate the issue or modify the sample you mentioned and please attach it to the report. Please be sure to also confirm if this happens with the latest 7.3 versions of Xamarin.Android.
Comment 3 Cody Beyer (MSFT) 2017-08-23 20:49:58 UTC
Because we have not received a reply to our request for more information we are closing this issue. If you are still encountering this issue, please reopen the ticket with the requested information. Thanks!