Bug 45368 - * Assertion at mini.c:2540, condition `code' not met
Summary: * Assertion at mini.c:2540, condition `code' not met
Status: NEW
Alias: None
Product: Runtime
Classification: Mono
Component: General (show other bugs)
Version: 4.6.0 (C8)
Hardware: PC Linux
: --- normal
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2016-10-13 16:31 UTC by Virtouse Lilienthal
Modified: 2016-10-14 07:24 UTC (History)
2 users (show)

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


Attachments

Description Virtouse Lilienthal 2016-10-13 16:31:34 UTC
On a heavy load system i run into this assertion all the time. This happens mainly to processes which have 1000 threads or more (which mainly are waiting for mutexes however)

The binaries are the same where this happens, however it happens at random locations however ends up in the mini.c part.

=====================================================================

First stack trace:

=====================================================================

Program received signal SIGABRT, Aborted.
[Switching to Thread 0x6e22c4c33700 (LWP 7991)]
0x00006e2394d525f7 in raise () from /lib64/libc.so.6
(gdb) bt
#0  0x00006e2394d525f7 in raise () from /lib64/libc.so.6
#1  0x00006e2394d53ce8 in abort () from /lib64/libc.so.6
#2  0x0000000000642352 in monoeg_log_default_handler (log_domain=0x0, log_level=G_LOG_LEVEL_ERROR, 
    message=0x6e21913af8b0 "* Assertion at mini.c:2540, condition `code' not met\n", unused_data=0x0) at goutput.c:233
#3  0x00000000006420dc in monoeg_g_logv (log_domain=0x0, log_level=G_LOG_LEVEL_ERROR, 
    format=0x64f1c8 "* Assertion at %s:%d, condition `%s' not met\n", args=0x6e22c4c305c0) at goutput.c:113
#4  0x000000000064229c in monoeg_assertion_message (format=0x64f1c8 "* Assertion at %s:%d, condition `%s' not met\n")
    at goutput.c:133
#5  0x00000000004fd001 in mono_codegen (cfg=0x6e2191385c90) at mini.c:2540
#6  0x000000000050011d in mini_method_compile (method="OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api:llSetTouchText ()", 
    opts=370239999, domain=0x6e21912b5f20, flags=<optimized out>, parts=0, aot_method_index=-1) at mini.c:4009
#7  0x0000000000501579 in mono_jit_compile_method_inner (method="OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api:llSetTouchText ()", 
    target_domain=0x6e21912b5f20, opt=370239999, jit_ex=0x6e22c4c30ab8) at mini.c:4263
#8  0x00000000004186be in mono_jit_compile_method_with_opt (
    method="OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api:llSetTouchText ()", opt=370239999, ex=0x6e22c4c30ab8)
    at mini-runtime.c:1952
#9  0x0000000000418a0b in mono_jit_compile_method (method="OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api:llSetTouchText ()")
    at mini-runtime.c:2008
#10 0x000000000041447b in mono_jit_create_remoting_trampoline (domain=0x6e21912b5f20, 
    method="OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api:llSetTouchText ()", target=MONO_REMOTING_TARGET_APPDOMAIN)
    at mini-runtime.c:2941
#11 0x00000000005b9770 in mono_class_proxy_vtable (domain=<optimized out>, remote_class=<optimized out>, target_type=<optimized out>)
    at object.c:2342
#12 0x00000000005b9c00 in mono_remote_class_vtable (domain=0x6e21912b5f20, remote_class=0x6e219135ce78, rp=0x6e238a929bb0)
    at object.c:2679
#13 0x0000000000536380 in ves_icall_Remoting_RealProxy_GetTransparentProxy (this_obj=0x6e238a929bb0, 
    class_name="OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api, OpenSim.Region.ScriptEngine.Shared.Api, Version=0.9.0.33089, Culture=neutral, PublicKeyToken=null") at icall.c:5859
#14 0x000000007ff1af11 in ?? ()
#15 0x00006e238a929bb0 in ?? ()
#16 0x00006e238a929bb0 in ?? ()
#17 0x00006e238a929bb0 in ?? ()
#18 0x00006e238a9272c8 in ?? ()
#19 0x00006e238a929bb0 in ?? ()
#20 0x00006e22c4c31340 in ?? ()
#21 0x00006e238a9272c8 in ?? ()
#22 0x0000000000000000 in ?? ()

=====================================================================

Second stack trace:

=====================================================================

Program received signal SIGABRT, Aborted.
[Switching to Thread 0x70cbd285c700 (LWP 21055)]
0x000070cca56875f7 in raise () from /lib64/libc.so.6
(gdb) bt
#0  0x000070cca56875f7 in raise () from /lib64/libc.so.6
#1  0x000070cca5688ce8 in abort () from /lib64/libc.so.6
#2  0x0000000000642352 in monoeg_log_default_handler (log_domain=0x0, log_level=G_LOG_LEVEL_ERROR, 
    message=0x70c989623440 "* Assertion at mini.c:2540, condition `code' not met\n", unused_data=0x0) at goutput.c:233
#3  0x00000000006420dc in monoeg_g_logv (log_domain=0x0, log_level=G_LOG_LEVEL_ERROR, 
    format=0x64f1c8 "* Assertion at %s:%d, condition `%s' not met\n", args=0x70cbd28573f0) at goutput.c:113
#4  0x000000000064229c in monoeg_assertion_message (format=0x64f1c8 "* Assertion at %s:%d, condition `%s' not met\n")
    at goutput.c:133
#5  0x00000000004fd001 in mono_codegen (cfg=0x70c989568b20) at mini.c:2540
#6  0x000000000050011d in mini_method_compile (method="System.Text.RegularExpressions.RegexCharClass:.cctor ()", opts=370239999, 
    domain=0x70c9894a1a30, flags=<optimized out>, parts=0, aot_method_index=-1) at mini.c:4009
#7  0x0000000000501579 in mono_jit_compile_method_inner (method="System.Text.RegularExpressions.RegexCharClass:.cctor ()", 
    target_domain=0x70c9894a1a30, opt=370239999, jit_ex=0x70cbd2857c18) at mini.c:4263
#8  0x00000000004186be in mono_jit_compile_method_with_opt (method="System.Text.RegularExpressions.RegexCharClass:.cctor ()", 
    opt=370239999, ex=0x70cbd2857c18) at mini-runtime.c:1952
#9  0x0000000000418dac in mono_jit_runtime_invoke (method="System.Text.RegularExpressions.RegexCharClass:.cctor ()", obj=0x0, 
    params=0x0, exc=0x70cbd2857dc8) at mini-runtime.c:2475
#10 0x00000000005b3ae9 in mono_runtime_invoke (method="System.Text.RegularExpressions.RegexCharClass:.cctor ()", obj=0x0, 
    params=0x0, exc=0x70cbd2857dc8) at object.c:2897
#11 0x00000000005bafbe in mono_runtime_class_init_full (vtable=vtable("System.Text.RegularExpressions.RegexCharClass"), 
    raise_exception=1) at object.c:396
#12 0x00000000414e1a12 in ?? ()
#13 0x000070c989569160 in ?? ()
#14 0x0000000000000002 in ?? ()
#15 0x000070cc987789d8 in ?? ()
#16 0x0000000000000000 in ?? ()



Linux x86_64/CentOS7.2

$mono --version
Mono JIT compiler version 4.6.1 (Stable 4.6.1.5/ef43c15 Wed Oct 12 08:27:19 UTC 2016)
Copyright (C) 2002-2014 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com
        TLS:           __thread
        SIGSEGV:       altstack
        Notifications: epoll
        Architecture:  amd64
        Disabled:      none
        Misc:          softdebug 
        LLVM:          supported, not enabled.
        GC:            sgen


RPMS from http://download.mono-project.com/repo/centos/

mono-data-4.6.1.5-0.xamarin.1.x86_64
mono-core-4.6.1.5-0.xamarin.1.x86_64
libmonoboehm-2_0-1-4.6.1.5-0.xamarin.1.x86_64
libmonosgen-2_0-1-4.6.1.5-0.xamarin.1.x86_64
mono-web-4.6.1.5-0.xamarin.1.x86_64
mono-winforms-4.6.1.5-0.xamarin.1.x86_64
libmono-2_0-1-4.6.1.5-0.xamarin.1.x86_64
libmonosgen-2_0-devel-4.6.1.5-0.xamarin.1.x86_64
mono-data-sqlite-4.6.1.5-0.xamarin.1.x86_64
mono-wcf-4.6.1.5-0.xamarin.1.x86_64
libmonoboehm-2_0-devel-4.6.1.5-0.xamarin.1.x86_64
mono-extras-4.6.1.5-0.xamarin.1.x86_64
mono-winfxcore-4.6.1.5-0.xamarin.1.x86_64
mono-mvc-4.6.1.5-0.xamarin.1.x86_64
libmono-2_0-devel-4.6.1.5-0.xamarin.1.x86_64


It's reproducible to me, basically with certain instances of those program all the time.
Comment 1 Virtouse Lilienthal 2016-10-14 07:17:03 UTC
===================================================================
One more with Full BT
===================================================================
(gdb) bt full
#0  0x00006c3ae531b5f7 in raise () from /lib64/libc.so.6
No symbol table info available.
#1  0x00006c3ae531cce8 in abort () from /lib64/libc.so.6
No symbol table info available.
#2  0x0000000000642352 in monoeg_log_default_handler (log_domain=0x0, log_level=G_LOG_LEVEL_ERROR, 
    message=0x6c38ab1184c0 "* Assertion at mini.c:2540, condition `code' not met\n", unused_data=0x0) at goutput.c:233
        target = 0x6c3ae56a2400 <_IO_2_1_stdout_>
#3  0x00000000006420dc in monoeg_g_logv (log_domain=0x0, log_level=G_LOG_LEVEL_ERROR, 
    format=0x64f1c8 "* Assertion at %s:%d, condition `%s' not met\n", args=0x6c3a130d55c0) at goutput.c:113
        msg = 0x6c38ab1184c0 "* Assertion at mini.c:2540, condition `code' not met\n"
#4  0x000000000064229c in monoeg_assertion_message (format=0x64f1c8 "* Assertion at %s:%d, condition `%s' not met\n")
    at goutput.c:133
        args = {{gp_offset = 32, fp_offset = 48, overflow_arg_area = 0x6c3a130d56a0, reg_save_area = 0x6c3a130d55e0}}
#5  0x00000000004fd001 in mono_codegen (cfg=0x6c38ab122e40) at mini.c:2540
        bb = <optimized out>
        max_epilog_size = 0
        code = 0x0
        code_domain = 0x6c38ab086490
#6  0x000000000050011d in mini_method_compile (method="OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api:llGetScriptName ()", 
    opts=370239999, domain=0x6c38ab086490, flags=<optimized out>, parts=0, aot_method_index=-1) at mini.c:4009
        header = 0x6c39c02c4ae8
        sig = <optimized out>
        err = {error_code = 0, hidden_0 = 0, hidden_1 = {0x0, 0x770000006e, 0x0, 0x6c3a130d57df, 0x6c38ab1d8770, 0x6c39c0000020, 
            0x14880, 0x7c, 0x6c38ab1dc7a0, 0x10850, 0x6c3ae5362f36 <_int_free+1494>, 0x40dbd38}, 
          hidden_2 = " \020\002\000\000\000\000\000\000\000\002\000\000\000\000\000 \000\000\300\071l\000\000\220X\r\023:l\000\000\200{\036\000\000\000\000\000 \000\000\000\000\000\000\000\200D,\253\070l\000\000\270Z\r\023:l\000\000pX\r\023:l\000\000%\212@\346:l\000\000\000\000\000\000\000\000\000\000\220%\020\253\070l\000\000\240J,\300\071l\000\000\377i\021\026", '\000' <repeats 12 times>, "\220X\r\023:l\000"}
        cfg = 0x6c38ab122e40
        dfn = 13
        i = <optimized out>
        code_size_ratio = <optimized out>
        try_generic_shared = 0
        method_to_compile = "OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api:llGetScriptName ()"
        method_to_register = "OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api:llGetScriptName ()"
        method_is_gshared = <optimized out>
        run_cctors = <optimized out>
        compile_aot = 0
        full_aot = 0
        disable_direct_icalls = 0
        gsharedvt_method = 0
        verbose_method_inited = 1
        verbose_method_name = 0x0
#7  0x0000000000501579 in mono_jit_compile_method_inner (method="OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api:llGetScriptName ()", 
    target_domain=0x6c38ab086490, opt=370239999, jit_ex=0x6c3a130d5ab8) at mini.c:4263
        cfg = <optimized out>
        code = 0x0
        jinfo = <optimized out>
        info = <optimized out>
        vtable = <optimized out>
        ex = 0x0
        prof_options = <optimized out>
        jit_timer = 0x6c38ab102590
        prof_method = <optimized out>
        shared = <optimized out>
#8  0x00000000004186be in mono_jit_compile_method_with_opt (
    method="OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api:llGetScriptName ()", opt=370239999, ex=0x6c3a130d5ab8)
    at mini-runtime.c:1952
        target_domain = 0x6c38ab086490
        domain = <optimized out>
        info = <optimized out>
        code = 0x0
        p = <optimized out>
        ji = <optimized out>
        callinfo = 0x0
        winfo = <optimized out>
#9  0x0000000000418a0b in mono_jit_compile_method (method="OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api:llGetScriptName ()")
    at mini-runtime.c:2008
        ex = 0x0
        code = <optimized out>
#10 0x000000000041447b in mono_jit_create_remoting_trampoline (domain=0x6c38ab086490, 
    method="OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api:llGetScriptName ()", target=MONO_REMOTING_TARGET_APPDOMAIN)
    at mini-runtime.c:2941
        nm = <optimized out>
        addr = 0x0
#11 0x00000000005b9770 in mono_class_proxy_vtable (domain=<optimized out>, remote_class=<optimized out>, target_type=<optimized out>)
    at object.c:2342
        cm = <optimized out>
        error = {error_code = 52696, hidden_0 = 43799, hidden_1 = {0x5b44bd <mono_remote_class+349>, 0x6c38ab1b1396, 0x6c38ab17cd40, 
            0x6c3a00000000, 0x1, 0x6c38ab1b1395, 0x6c38ab1b1395, 0x3900000072, 0xab1a1990, 0x0, 
            0x5e8a7c <sgen_try_alloc_obj_nolock+156>, 0x6c3a130d5b2c}, 
          hidden_2 = "|\212^\000\000\000\000\000(\000\000\000\000\000\000\000`2\024\253\070l\000\000\310\377\377\377\377\377\377\377\000\207\r\023:l\000\000\000\271\035\330:l\000\000\343\217^", '\000' <repeats 13 times>, "\n~]\000\000\000\000\000\220d\b\253\070l\000\000`2\024\253\070l\000\000\000\271\035\330:l\000\000\220d\b\253\070l\000\000\350\315\027\253\070l\000\000\220d\b\253\070l\000\000\000\271\035\330:l\000"}
        vt = vtable("OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api")
        pvt = vtable("System.Runtime.Remoting.Proxies.TransparentProxy")
        i = <optimized out>
        j = <optimized out>
        vtsize = <optimized out>
        max_interface_id = 3597
        extra_interface_vtsize = <optimized out>
        k = <optimized out>
        extra_interfaces = <optimized out>
        klass = "OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api"
        interface_offsets = 0x6c38ab19eea8
        bitmap = <optimized out>
        bsize = <optimized out>
        imt_table_bytes = 152
#12 0x00000000005b9c00 in mono_remote_class_vtable (domain=0x6c38ab086490, remote_class=0x6c38ab17cde8, rp=0x6c3ad81db900)
    at object.c:2679
No locals.
#13 0x0000000000536380 in ves_icall_Remoting_RealProxy_GetTransparentProxy (this_obj=0x6c3ad81db900, 
    class_name="OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api, OpenSim.Region.ScriptEngine.Shared.Api, Version=0.9.0.33089, Culture=neutral, PublicKeyToken=null") at icall.c:5859
        domain = 0x6c38ab086490
        res = 0x6c3ad81dba50
        rp = 0x6c3ad81db900
        tp = 0x6c3ad81dba50
        type = <optimized out>
        klass = "OpenSim.Region.ScriptEngine.Shared.Api.LSL_Api"
#14 0x000000007ff4af11 in ?? ()
No symbol table info available.
#15 0x00006c3ad81db900 in ?? ()
No symbol table info available.
#16 0x00006c3ad81db900 in ?? ()
No symbol table info available.
#17 0x00006c3ad81db900 in ?? ()
No symbol table info available.
#18 0x00006c3ad81d9fc8 in ?? ()
No symbol table info available.
#19 0x00006c3ad81db900 in ?? ()
No symbol table info available.
#20 0x00006c3a130d6340 in ?? ()
No symbol table info available.
#21 0x00006c3ad81d9fc8 in ?? ()
No symbol table info available.
#22 0x0000000000000000 in ?? ()
No symbol table info available.

===================================================================
Comment 2 Virtouse Lilienthal 2016-10-14 07:24:33 UTC
A common thing I notice seems to be a code size in between 800 and 900 bytes, but that could be coincidental

Note You need to log in before you can comment on or make changes to this bug.