Daniel Kuhne | 28 Jul 10:24 2015
Picon

condition `class' not met

Hello,

I am getting assertion:

* Assertion at class.c:5078, condition `class' not met


Native stacktrace:

        mono() [0x48f940]

=================================================================
Got a SIGABRT while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
=================================================================

Aborted


Any idea?
Cheers,
Daniel
_______________________________________________
Mono-devel-list mailing list
Mono-devel-list <at> lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list
Taloth Saldono | 23 Jul 14:03 2015
Picon

Investigating mono crashes on linux 4.1

Hey guys,

(Initially I incorrectly posted this to the mono-list, so for those receiving this message twice, my apologies.)

I'm looking for a mono expert on the managed threading system, hopefully you can give me a pointer to where to look.

The problem a couple of my users experience is that since linux kernel 4.1 mono crashes in a reproducible manner. (Using test case bug-18026 in a loop, which is a threadpool stress-test)

A similar problem occurred in 3.13.0 but that was fixed by backporting some commits in the ubuntu kernel. (See https://bugzilla.xamarin.com/show_bug.cgi?id=29212)

Initially I believed that in 4.1 those commits were reverted, but tests indicated that wasn't the cause.
So I did a full bisect on linux 4.0-4.1 on a 64-bit Ubuntu 14.04.2 Virtualbox. (~13 compiles of the kernel, took a couple of days)

The problem seems to cause NullReferenceException and possibly native SIGSEGVs in a variety of places. (I can dump some stacktraces if desired, but I suspect that won't be helpful coz the corruption is likely caused elsewhere.)

To me it seems impossible that reading the tsc in any way could result in the nullrefs. So my guess would it a side-effect of the memory barrier. From what I understand from the commit, the 'mfence+lfence' changed to 'mfence or lfence' (depending on what the cpu supports) and mfrence=lfence+sfence (not entirely true, but close), so I have no idea what the heck is going on there.
But if I would venture a guess that somewhere, indirectly, mono unknowingly relies on that barrier to be there.
Theoretically it still means other native apps could experience the same problem, but I would've expected reports about that already.

My experience in these matters is pretty much non-existent. But dumping issues on devs is the least productive way to get them fixed, so I try to investigate as far as I can. Especially since it involves an issue that could be caused by either mono or the kernel.

So my question is: Is there a likely candidate in mono where it uses the tsc (possibly for profiling) where the changed barrier could cause this odd behavior? And obviously, is there anything in particular I could try to narrow this down further?

Almost forgot, but I did the bisect using mono 4.0.2.5, but I tested the nightly version as well.

Thank you for your time.

Taloth
_______________________________________________
Mono-devel-list mailing list
Mono-devel-list <at> lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list
Jonathan Mitchell | 20 Jul 13:37 2015

OS X 64 bit stuff

HI

Some of us use 64 bit Mono on OS X.
The current binary download is currently deficient by 32bits.

So:

1. Is there a timeline for a 64 bit OS X framework release? A few months ago the answer was no.

2. I think that Xamarin.mac supports 64 bits. Does this use a discrete 64 library build as opposed to a
standard OS X framework bundle?

3. The OS X mono framework is apparently built with https://github.com/mono/bockbuild. That repo his
pretty opaque. 
https://github.com/mono/bockbuild/blob/master/bockbuild/darwinprofile.py looks like it might be
able to handle a 64 bit build. Am I on the right track there?

Jonathan
techi eth | 17 Jul 10:43 2015
Picon

Obfuscate dll with mono

Hi,

How can i do dll obfuscate with mono on linux ?

Regards,
Techi
_______________________________________________
Mono-devel-list mailing list
Mono-devel-list <at> lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list
Jerod Venema | 17 Jul 04:07 2015

Bugs

Hey guys,

I've got a bit of a sticky error. I don't have any native code in this particular application, but what I'm seeing is after some time of running (this is a server-side app running via upstart on Ubuntu), I get this nasty error.

* Assertion at metadata.c:965, condition `idx < t->rows' not met

Stacktrace:

  at <unknown> <0xffffffff>
  at (wrapper managed-to-native) System.Reflection.MonoMethodInfo.get_parameter_info (intptr,System.Reflection.MemberInfo) <0xffffffff>
  at System.Reflection.MonoMethodInfo.GetParametersInfo (intptr,System.Reflection.MemberInfo) <0x00011>
  at System.Reflection.MonoMethod.GetParametersInternal () <0x00013>
  at System.Exception.GetFullNameForStackTrace (System.Text.StringBuilder,System.Reflection.MethodBase) <0x0002d>
  at System.Exception.AddFrames (System.Text.StringBuilder,string,string,System.Diagnostics.StackTrace) <0x00174>
  at System.Exception.get_StackTrace () <0x00158>
  at System.Exception.ToString () <0x000fc>
  at (wrapper runtime-invoke) <Module>.runtime_invoke_object__this__ (object,intptr,intptr,intptr) <0xffffffff>

Native stacktrace:

        mono() [0x4b20bc]
        /lib/x86_64-linux-gnu/libpthread.so.0(+0x10340) [0x7fd05dd3b340]
        /lib/x86_64-linux-gnu/libc.so.6(gsignal+0x39) [0x7fd05d99ccc9]
        /lib/x86_64-linux-gnu/libc.so.6(abort+0x148) [0x7fd05d9a00d8]
        mono() [0x6294f9]
        mono() [0x629707]
        mono() [0x629856]
        mono(mono_metadata_decode_row+0xd3) [0x55d503]
        mono(mono_method_get_param_names+0x224) [0x546ec4]
        mono() [0x5c5294]
        [0x416b4e28]

Debug info from gdb:


=================================================================
Got a SIGABRT while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
=================================================================

Anyone have any suggestions on what might be causing this or something I can do to avoid it?

--
Jerod Venema

Frozen Mountain Software
919-300-5141 (United States)
604-227-2453 (Canada)
888-379-6686 (Toll Free)
_______________________________________________
Mono-devel-list mailing list
Mono-devel-list <at> lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list
Niamh Holding | 11 Jul 11:06 2015
Picon

Re: Error trying to compile mono on CentOs 5


Hello,

Jun 10, 2015; 9:09pm   Timotheus Pokorra wrote

> I have just built the Mono 4.0.1.44 packages for CentOS5, 32 bit and 64 bit.

Just installed this on 32 bit CentOS5 and am seeing-

Unhandled Exception:
System.TypeInitializationException: An exception was thrown by the type initializer for
Mono.Unix.Native.Syscall ---> System.DllNotFoundException: /opt/mono/lib/libMonoPosixHelper.so

Is libMonoPosixHelper.so not included?

--

-- 
Best regards,
 Niamh                          mailto:niamh <at> fullbore.co.uk
Daniel Kuhne | 7 Jul 14:36 2015
Picon

meta-mono does not build for arm64

Hello,

does mono support arm64?

we used meta-mono with dora and arm32 and that worked. now we try with fido and arm64 and we fail to build mono:

../../doltcompile aarch64-gnu-linux-gcc  --sysroot=/home/daniel/BUILD/
YOCTO/ESX/build/tmp-glibc/sysroots/qemuarm64 -DHAVE_CONFIG_H -I. -I../..  -I../.. -I../../mono -I../../libgc/include -I../../eglib/src -I../../eglib/src -DGC_LINUX_THREADS -D_GNU_SOURCE -D_REENTRANT -DUSE_MMAP -DUSE_MUNMAP  -DUSE_COMPILER_TLS  -O2 -pipe -g -feliminate-unused-debug-types -fno-strict-aliasing -fwrapv -Wdeclaration-after-statement -Wno-unused-but-set-variable -g -Wall -Wunused -Wmissing-prototypes -Wmissing-declarations -Wstrict-prototypes  -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wno-cast-qual -Wwrite-strings -Wno-switch -Wno-switch-enum -Wno-unused-value -Werror-implicit-function-declaration -c -o mono-io-portability.lo mono-io-portability.c
| In file included from ../../mono/utils/mono-stack-unwinding.h:10:0,
|                  from ../../mono/metadata/object-internals.h:13,
|                  from ../../mono/metadata/gc-internal.h:14,
|                  from mono-io-portability.c:13:
| ../../mono/utils/mono-context.h:288:43: fatal error: mono/arch/arm64/arm64-codegen.h: No such file or directory
|  #include <mono/arch/arm64/arm64-codegen.h>
|                                            ^
| compilation terminated.
| make[4]: *** [mono-io-portability.lo] Error 1
| make[4]: *** Waiting for unfinished jobs....
| make[4]: Leaving directory `/home/daniel/BUILD/YOCTO/ESX/build/tmp-glibc/work/aarch64-gnu-linux/mono/3.12.1-r0/mono-3.12.1/mono/utils'
| make[3]: *** [all] Error 2
| make[3]: Leaving directory `/home/daniel/BUILD/YOCTO/ESX/build/tmp-glibc/work/aarch64-gnu-linux/mono/3.12.1-r0/mono-3.12.1/mono/utils'
| make[2]: *** [all-recursive] Error 1
| make[2]: Leaving directory `/home/daniel/BUILD/YOCTO/ESX/build/tmp-glibc/work/aarch64-gnu-linux/mono/3.12.1-r0/mono-3.12.1/mono'
| make[1]: *** [all-recursive] Error 1
| make[1]: Leaving directory `/home/daniel/BUILD/YOCTO/ESX/build/tmp-glibc/work/aarch64-gnu-linux/mono/3.12.1-r0/mono-3.12.1'
| make: *** [all] Error 2
| ERROR: oe_runmake failed
| WARNING: exit code 1 from a shell command.
| ERROR: Function failed: do_compile (log file is located at /home/daniel/BUILD/YOCTO/ESX/build/tmp-glibc/work/aarch64-gnu-linux/mono/3.12.1-r0/temp/log.do_compile.3699)
ERROR: Task 661 (/home/daniel/BUILD/YOCTO/ESX/poky/../meta-mono/recipes-mono/mono/mono_3.12.1.bb, do_compile) failed with exit code '1'

BR,
Daniel

_______________________________________________
Mono-devel-list mailing list
Mono-devel-list <at> lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list
Neale Ferguson | 5 Jul 13:09 2015
Picon

nunit-console

I have a series of tests for the c# mongodb driver of the form:

        [Test]
        public async Task QueryAll()
        {


I had successfully run nunit-console4 against the dll that xbuild created
but just suddenly the tests started to be not run with nunit-console
complaining: Method QueryAll's signature is not correct: it must return
void

However, the nunit-console doc states that async Task tests are valid.

I have no idea what’s changed. Yes I know things don’t suddenly stop
working for no reason at all, but what I am trying to determine is what
that change was that would cause the tests to behave as they now are.

Neale

_______________________________________________
Mono-devel-list mailing list
Mono-devel-list <at> lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list
Elmar Haneke | 3 Jul 11:24 2015
Picon

CallingCopnvention.stdcall

There seems to be an incompaible change in CallingConventions on 32Bit
Windows.

The "stdcall" should be the same as "winapi".

But on Mono 4 "stdcall" sems to be broken and changing to "winapi" does
fix the problem.

Elmar
Howard Rubin | 25 Jun 22:05 2015
Picon

Errors Compiling for x64 Windows

Goal: Embed mono in a 64 bit C++ Windows program (http://www.mono-project.com/docs/about-mono/languages/mixing-with-other-languages/)

 

What I tried:

Downloaded the ZIP file from github (https://github.com/mono/mono , https://github.com/mono/mono/archive/master.zip)

Read Windows compile instructions (http://www.mono-project.com/docs/compiling-mono/windows/)

Installed Cygwin with the recommended packages

Set the MONO_DEPENDENCIES_PREFIX environment variable to C:\Program Files (x86)\Mono\

Tried to compile the 6 projects in the Libraries folder with Visual Studio 2010 (in Debug/Win32) because msvc\mono.sln was last saved with that Visual Studio version.

        Result:  error MSB8008: Specified platform toolset (v120) is not installed or invalid. <snip>

Compiled the 6 projects in the Libraries folder with Visual Studio 2013 express (in Debug/Win32) Result: Success

Switched to Debug/x64 configuration

Tried to compile the 6 projects in the Libraries folder with Visual Studio 2013 express.

        Result: error C1189: #error :  Unsupported compiler.  <snip> mono-master\mono\utils\valgrind.h      454        1             libmono

 

Please help me compile mono for x64 Windows

 

Howard Rubin

 

_______________________________________________
Mono-devel-list mailing list
Mono-devel-list <at> lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list
Gutemberg Ribeiro | 19 Jun 19:11 2015

Re: Cross-compiling Mono for ARM

Hello Andres...

I think I finally got it compiled but, now when I'm including on my C project the mono headers, my app don't
compile anymore:

In file included from ../../Desktop/mono-build/usr/local/include/mono-2.0/mono/utils/mono-publib.h:45,
                 from ../../Desktop/mono-build/usr/local/include/mono-2.0/mono/metadata/appdomain.h:13,
                 from ../../Desktop/mono-build/usr/local/include/mono-2.0/mono/jit/jit.h:11,
                 from C:/Users/Gutemberg/IngeDev7_workspace/MonoWrapper/Inc/mono_loader.h:1,
                 from
Src/Entry.c:43:
/cygdrive/c/Ingenico/IngeDev_7.22.2.1/plugins/com.ingenico.ingedev.telium.bin.win32.gnuarm.v434_7.20.0.1/os/win32/GNUARM/4.3.4/bin/../lib/gcc/arm-elf/4.3.4/../../../../arm-elf/include/stdint.h:243:
error: conflicting types for 'intptr_t'
C:/Ingenico/TeliumSDK/SDK 9.20.2.04/SDKTPLUS/HW_T2/gnu_434/inc/oem_vfs_def.h:35: error:
previous declaration of 'intptr_t' was
here
/cygdrive/c/Ingenico/IngeDev_7.22.2.1/plugins/com.ingenico.ingedev.telium.bin.win32.gnuarm.v434_7.20.0.1/os/win32/GNUARM/4.3.4/bin/../lib/gcc/arm-elf/4.3.4/../../../../arm-elf/include/stdint.h:244:
error: conflicting types for 'uintptr_t'
C:/Ingenico/TeliumSDK/SDK 9.20.2.04/SDKTPLUS/HW_T2/gnu_434/inc/oem_vfs_def.h:38: error:
previous declaration of 'uintptr_t' was
here
C:\Ingenico\IngeDev_7.22.2.1\plugins\com.ingenico.ingedev.generic.bin.win32_7.16.0.1\os\win32\tools\make.exe:
*** [Obj/GNU_ARM_DEBUG/Entry.o] Error
1
C:\Ingenico\IngeDev_7.22.2.1\plugins\com.ingenico.ingedev.generic.bin.win32_7.16.0.1\os\win32\tools\make.exe:
Target `build' not remade because of errors.

Any clues?

Thanks

-----Original Message-----
From: Andres G. Aragoneses [mailto:knocte <at> gmail.com] 
Sent: Friday, June 19, 2015 8:58 AM
To: Gutemberg Ribeiro <gutemberg <at> fgrit.com>
Subject: Re: Cross-compiling Mono for ARM

On 18/06/15 21:03, Gutemberg Ribeiro wrote:
> Hello guys,
>
> I'm trying to cross-compile (from Ubuntu 14.04) Mono for ARM following 
> this tutorial 
> http://www.mono-project.com/docs/about-mono/supported-platforms/arm/ 
> but the links that show how configure ScratchBox are outdated and I 
> can't find anything on the internet on how to successful setup an 
> environment and cross-compile mono for ARM...
>
> The idea is to build it as a static library so I can use it embedded 
> as suggested here: 
> http://www.mono-project.com/docs/advanced/embedding/
>
> For the sake of information, the target ARM device runs a proprietary 
> striped down distribution based on debian and we have no access to its 
> terminal or any kind of access to the OS. It is a payment terminal 
> from www.ingenico.com <http://www.ingenico.com> and it has an ARM9 
> processor and uses a proprietary SDK that looks like uses GNU ARM 
> 4.3.4 toolchain with an IDE based on Eclipse as you can see in the following picture:
>
> The only way we have to use mono on it is by adding it as a static lib 
> and import the header in order to embedded it, create a thin C layer 
> that will only bootstrap the .net app (all their API calls will be 
> PInvoked after add Mono to it).
>
> Anyone has has a good documentation on:
>
> 1.How to setup a cross-compile environment on Ubuntu
>
> 2.Compile Mono to ARM as an static library
>
> Any help would be very appreciated.
>
> Thank you very much!
>
> Best regards,

Hey, I recommend you to put more details on what you have already tried. 
For example the details you already posted on the gitter channel when you were talking with Miguel about
using CC='armv6-cc' ./configure.

Gmane