From: SourceForge.net <no...@so...> - 2007-04-18 14:20:49
|
Bugs item #1702565, was opened at 2007-04-18 00:23 Message generated for change (Comment added) made by wsfulton You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=101645&aid=1702565&group_id=1645 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: csharp Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Richard Boulton (richardb) Assigned to: William Fulton (wsfulton) Summary: CSharp bindings and test-suite fail with memory errors Initial Comment: I have been having a problem for a while now with the SWIG generated bindings for Xapian, which fail by displaying a "free(): invalid pointer" error message, and then hanging indefinitely. Olly Betts pointed me at the "make check-csharp-test-suite" target for SWIG, which generates lots of errors for me (whether or not the errors are the same is unclear to me, but they certainly don't look good). A log of the output generated by running "make check-csharp-test-suite" is attached. This output ends with the "constover" test, at which point the process hung indefinitely until I pressed CTRL-C. I'm running Ubuntu Feisty, with: $ mono --version Mono JIT compiler version 1.2.3.1, (C) 2002-2006 Novell, Inc and Contributors. www.mono-project.com TLS: __thread GC: Included Boehm (with typed GC) SIGSEGV: normal Architecture: x86 Disabled: none $ mcs --version Mono C# compiler version 1.2.3.1 The "make check-csharp-test-suite" target passes with no errors for Olly, on a different machine with Mono JIT compiler version 1.1.17.1 For reference, details of the bug with Xapian are at http://www.xapian.org/cgi-bin/bugzilla/show_bug.cgi?id=132 ---------------------------------------------------------------------- >Comment By: William Fulton (wsfulton) Date: 2007-04-18 14:20 Message: Logged In: YES user_id=242951 Originator: NO I can replicate the failures on Ubuntu Dapper Drake with the exact same mono and mcs versions. All I can say is I hope this isn't the default mono setup going into Feisty as there is something completely broken. The classic SWIG C# C++ example is in Examples/csharp/class. This one seg faults. I've narrowed the problem down to this most basic of runtime tests (replace the contents of runme.cs with the following): using System; public class runme { static void Main() { Shape shape = new Square(10); shape.x = -10; shape.y = 5; } } I think this needs to be investigated a bit further. But cutting out all the unnecessary initialisation code then submitting it all as a bug to mono is probably the next step. ---------------------------------------------------------------------- Comment By: Richard Boulton (richardb) Date: 2007-04-18 01:09 Message: Logged In: YES user_id=9565 Originator: YES We've found that moving to compile with gmcs instead of mcs fixes the Xapian bug, and is apparently needed to target the "mono 2.0" runtime (ie, mono versions from 1.2 onwards), so that is probably the fix for this issue. I haven't been able to fiddle the swig build system to make this change, but compiling a couple of the tests manually using gmcs instead of mcs seems to make them work. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=101645&aid=1702565&group_id=1645 |