Skip to content

dotnet 7 causes Segmentation fault on arm64 platforms #93047

Closed

Description

@gnattu

Description

When I'm trying to test Jellyfin with recent dotnet 7 upgrade, I noticed that the library scan would cause segfault on all arm64 platforms I've been tested on(Linux and macOS). When doing a library scan with lots of video files, which I have 80 in my test folder and it reliably caused the segfault).

I've tested x86-64 on Windows and it runs fine, which led me to believe this is an arm64 specific issue.

I also noticed that if you try to attach a dotnet debugger to the process, the segfault would gone.

What I've tried to workaround this so far:

  • Use COMPlus_GCName=libclrgc.so, still segfaults
  • Use server gc, still segfaults

I also tried to get a coredump for the process, but it is too big to upload here. If that is needed please let me know.

Reproduction Steps

I'm sorry I cannot come up with a simpler reproduction step because it is hard for me to extract a code pattern that would cause the segfault. So I will tell you how to reproduce it with jellyfin:

  • Initial account creation may not be triggered for the master branch, so I would suggest you to install a release version of Jellyfin 10.8.11, start that first, then complete the account creation step in the web UI but don't add any library folders yet.
git clone https://github.com/jellyfin/jellyfin.git
cd jellyfin
dotnet publish --config Release
cd /Jellyfin.Server/bin/Release/net7.0
# if you are on Linux, you should mv jellyfin jellyfin-server
wget https://repo.jellyfin.org/releases/server/portable/versions/unstable/web/20231005.2/jellyfin-web_20231005.2_portable.tar.gz
tar xvf jellyfin-web_20231005.2_portable.tar.gz
mv jellyfin-web_20231005.2 jellyfin-web
# change the data-dir to the path pointed by the one created by the release version of Jellyfin 10.8.11
./jellyfin-server --datadir ~/jellyfin-data

After that, go to localhost:8096, log in with the account created by the release version, and add a media library that points to the folder containing a lot of video files. Mine are all h264 encoded in mp4 or flv containers. (You can find the option at the menu button at the top left corner. Click on Dashboard, then click on Libraries.)

You will see a segfault near the end of the Library scan.

Expected behavior

The Library scan should success.

Actual behavior

dotnet runtime segfaults.

Regression?

No response

Known Workarounds

No response

Configuration

mcr.microsoft.com/dotnet/sdk:7.0-bookworm-slim docker image on Linux arm64
dotnet 7.0.401 on macOS 14.0 arm64

Other information

No response

Activity

  1. ghost added
    needs-area-label
    on Oct 5, 2023
  2. ghost added
    untriaged
    on Oct 5, 2023
  3. EgorBo commented on Oct 5, 2023

    @EgorBo
    Member

    Can you please check with DOTNET_EnableWriteXorExecute=0 env variable and separately with DOTNET_JITMinOpts=1

  4. gnattu commented on Oct 5, 2023

    @gnattu
    Author

    I tried DOTNET_EnableWriteXorExecute=0, and it still segfaults. However, with DOTNET_JITMinOpts=1, the segfaults seem to be gone for me. I've tested multiple folders multiple times and have not triggered a segfault so far. I'm going to use this as the workaround for the moment.

  5. added
    area-CodeGen-coreclr
    and removed
    needs-area-label
    on Oct 5, 2023
  6. EgorBo commented on Oct 5, 2023

    @EgorBo
    Member

    Thanks! Smells like a codegen issue then - can you possibly try with a public version .NET 8.0 RC1 (or better RC2 once it's released)?

  7. jakobbotsch commented on Oct 5, 2023

    @jakobbotsch
    Member

    Does it reproduce with DOTNET_JitEnablePhysicalPromotion=0?

  8. gnattu commented on Oct 5, 2023

    @gnattu
    Author

    @jakobbotsch Yes, it still segfaults with DOTNET_JitEnablePhysicalPromotion=0

  9. jakobbotsch commented on Oct 5, 2023

    @jakobbotsch
    Member

    Did this work in a previous .NET 7 release? Or did you upgrade from a previous major version?

  10. gnattu commented on Oct 5, 2023

    @gnattu
    Author

    I've tested this with dotnet version as early as 7.0.102 and still encountering the issue. I have not tested in previous dotnet 7 releases.

    The current master is using some methods introduced in dotnet7, but if I revert these commits and do a quick dirty test on dotnet 6.0.400, the segfault is gone.

  11. gnattu commented on Oct 5, 2023

    @gnattu
    Author

    can you possibly try with a public version .NET 8.0 RC1 (or better RC2 once it's released)?

    @EgorBo Sorry, I pulled the 8.0 RC1 Docker image, but our codebase is not working well with .NET 8.0 and cannot be tested with a simple upgrade. We're encountering a lot of compiler errors like the CS0104 and need manual modifications. I attempted to fix these, but it seems like something went wrong or it's indeed broken in 8.0. The server cannot find the network config and cannot be started after my modifications. I'm sorry, but I probably can't test any further on 8.0, as it requires some work for a proper migration, and we're not planning on upgrading to 8.0 yet.

  12. added this to the 8.0.0 milestone on Oct 9, 2023
  13. 5 remaining items

  14. added this to the 9.0.0 milestone on Oct 10, 2023
  15. gnattu commented on Oct 10, 2023

    @gnattu
    Author

    @kunalspathak

    I tried on windows/arm64 and it works fine for me. I am wondering if you have windows/arm64 machine to try out?

    I don't have bare metal Windows arm64 machine, but I started an Windows 11 arm64 VM and tested on that. The same folder indeed did not segfaults on windows arm64.

    Tested on : Windows 11 Pro 22H2, build 22621.2134 arm64, dotnet 7.0.402

    On macOS, the exact version dotnet 7.0.402, it segfaults.

    Also, when you say there is a segfault, does the server process crashes or some other symptoms to look for?

    It crashes. To have a better understanding of what happened you can go to jellyfin-data dir, look for config folder, and you will find (or to create) a logging.json and set logging level to debug:

    {
      "Serilog": {
        "MinimumLevel": "Debug"
      }
    }

    Then you will find that the segfault would occur when the scan progress is near to an end:

    [04:28:31] [DBG] [14] MediaBrowser.Providers.Manager.ProviderManager: OnRefreshProgress 574881e82adf616c66fc66d5d1527696 98.5625
    zsh: segmentation fault
    

    Pay attention to OnRefreshProgress because most of the time the segfault occurs when OnRefreshProgress is close to 100, in rare case, it could finish to 100 and get OnRefreshComplete printed, but it would still segfault after that.

    Also, is there a different way to reproduce this problem in console based OS? Probably some unit test or something that you can come up with which can help me repro it on my Linux console?

    Sorry but all our unit test files are passed, which makes this problem tricky. I used a docker container and redirected its port, so that I can use my browser to connect it remotely, despite the container/linux host been cli based. My method of testing is that:

    • Pull the official dotnet docker image
    • Bind mount everything needed, the jellyfin source, the jellyfin-web dir, the jellyfin-data(you can use the one created with windows to make your life easier, and you can login with the accounts created with windows then), and the video folders.
    • Redirect container port 8096 to a port you preferred on your host
    • Use the method provided before, do a dotnet publish with Release config, and then copy the jellyfin-web folder to the published folder.
    • On linux you need to mv jellyfin jellyfin-server because jellyfin will want to create a config folder at its working dir.
    • After that you start that server with something like: ./jellyfin-server --datadir ~/jellyfin-data
    • Point your browser to http:your-machine-ip:your-port, and login, then remove all old libraries as their paths would be invalid, then add a new library points to your mounted dir

    If you want to test it without a container, the procedure is similar, just running it directly instead. Jellyfin defaults to listen on 0.0.0.0 so you don't need to do extra configuration to get remote connection.

    Some things to note during testing:

    1. The folder need to contain enough items, only a few videos would not trigger segfault. I can reliably reproduce this with around 50 video files
    2. If you want to test rescan with the option Refresh metadata, you need to choose Replace all metadata, other options do not trigger segfault.
    3. You need to have ffmpeg in your $PATH, so if you use docker, you need to do apt install ffmpeg.
  16. kunalspathak commented on Oct 25, 2023

    @kunalspathak
    Contributor

    @gnattu - is it possible to get the native callstack when it seg faults? I just investigated #93912 of a crash in net7/arm64 and was caused because of Vector128.Load. I looked through the jellyfin codebase and don't see any references of Vector128, but some other dependency might be using it. Curious to see if it is the same reason.

  17. gnattu commented on Oct 25, 2023

    @gnattu
    Author

    @kunalspathak I tried to get a backtrace using lldb but the backtrace does not show many useful data:

    * thread #29, name = '.NET ThreadPool Worker', stop reason = signal SIGUSR1
      * frame #0: 0x000000010f817860
        frame #1: 0x000000010526e08c
        frame #2: 0x000000010ee3a108
        frame #3: 0x000000010ee397c0
        frame #4: 0x000000010d0ad208
        frame #5: 0x000000010f81ee7c
        frame #6: 0x000000010f81ebe8
        frame #7: 0x000000010f81e9e0
        frame #8: 0x000000010f81e530
        frame #9: 0x000000010f81b3f0
        frame #10: 0x000000010f81b2a0
        frame #11: 0x000000010f81b238
        frame #12: 0x000000010d0f11dc
        frame #13: 0x000000010e306024
        frame #14: 0x000000010e305f00
        frame #15: 0x000000010f81b158
        frame #16: 0x000000010f81a89c
        frame #17: 0x000000010f81a324
        frame #18: 0x000000010f809a08
        frame #19: 0x000000010f809254
        frame #20: 0x000000010f8091a0
        frame #21: 0x000000010f809140
        frame #22: 0x000000010f804404
        frame #23: 0x000000010f804274
        frame #24: 0x000000010f8041c0
        frame #25: 0x000000010f80415c
        frame #26: 0x000000010f82fb4c
        frame #27: 0x000000010f82f820
        frame #28: 0x000000010f82effc
        frame #29: 0x000000010f82ed90
        frame #30: 0x000000010f82e934
        frame #31: 0x000000010f82e4a0
        frame #32: 0x000000010f82e0ac
        frame #33: 0x000000010f82cdb0
        frame #34: 0x000000010f82c5fc
        frame #35: 0x000000010f0a5ad0
        frame #36: 0x000000010f12f7a8
        frame #37: 0x000000010e2dd384
        frame #38: 0x0000000104f3d9f8
        frame #39: 0x0000000104f14014
        frame #40: 0x0000000100def774 libcoreclr.dylib`CallDescrWorkerInternal + 132
        frame #41: 0x0000000100c650f0 libcoreclr.dylib`DispatchCallSimple(unsigned long*, unsigned int, unsigned long, unsigned int) + 272
        frame #42: 0x0000000100c7980c libcoreclr.dylib`ThreadNative::KickOffThread_Worker(void*) + 148
        frame #43: 0x0000000100c3352c libcoreclr.dylib`ManagedThreadBase_DispatchOuter(ManagedThreadCallState*) + 260
        frame #44: 0x0000000100c33a98 libcoreclr.dylib`ManagedThreadBase::KickOff(void (*)(void*), void*) + 32
        frame #45: 0x0000000100c798e4 libcoreclr.dylib`ThreadNative::KickOffThread(void*) + 172
        frame #46: 0x0000000100b51330 libcoreclr.dylib`CorUnix::CPalThread::ThreadEntry(void*) + 380
        frame #47: 0x000000018f2a3034 libsystem_pthread.dylib`_pthread_start + 136
    (lldb)
    

    Is there anything I have to do to show more detailed data?

  18. gnattu commented on Oct 25, 2023

    @gnattu
    Author

    I just used captured another and this time it comes with more useful info:

    (lldb) bt
    * thread #30, name = '.NET ThreadPool Worker', stop reason = signal SIGUSR1
      * frame #0: 0x000000018f2660ac libsystem_kernel.dylib`__psynch_cvwait + 8
        frame #1: 0x000000018f2a35fc libsystem_pthread.dylib`_pthread_cond_wait + 1228
        frame #2: 0x0000000100b424b8 libcoreclr.dylib`CorUnix::CPalSynchronizationManager::ThreadNativeWait(CorUnix::_ThreadNativeWaitData*, unsigned int, CorUnix::ThreadWakeupReason*, unsigned int*) + 280
        frame #3: 0x0000000100b42148 libcoreclr.dylib`CorUnix::CPalSynchronizationManager::BlockThread(CorUnix::CPalThread*, unsigned int, bool, bool, CorUnix::ThreadWakeupReason*, unsigned int*) + 348
        frame #4: 0x0000000100b46964 libcoreclr.dylib`SleepEx + 160
        frame #5: 0x0000000100ca7490 libcoreclr.dylib`__SwitchToThread(unsigned int, unsigned int) + 20
        frame #6: 0x0000000100de49d4 libcoreclr.dylib`WKS::CFinalize::RegisterForFinalization(int, Object*, unsigned long) + 392
        frame #7: 0x0000000100de47e4 libcoreclr.dylib`WKS::GCHeap::Alloc(gc_alloc_context*, unsigned long, unsigned int) + 104
        frame #8: 0x0000000100ca3740 libcoreclr.dylib`Alloc(unsigned long, GC_ALLOC_FLAGS) + 192
        frame #9: 0x0000000100ca437c libcoreclr.dylib`AllocateObject(MethodTable*) + 104
        frame #10: 0x0000000100cbe7c0 libcoreclr.dylib`JIT_New(CORINFO_CLASS_STRUCT_*) + 124
        frame #11: 0x0000000105270444
        frame #12: 0x000000010510fa7c
        frame #13: 0x00000001050c322c
        frame #14: 0x000000010f7f4430
        frame #15: 0x000000010f7f4338
        frame #16: 0x000000010d187910
        frame #17: 0x000000010f7f4224
        frame #18: 0x000000010f7f3b08
        frame #19: 0x000000010f84994c
        frame #20: 0x000000010f8494a4
        frame #21: 0x000000010f838b88
        frame #22: 0x000000010f8383d4
        frame #23: 0x000000010f838320
        frame #24: 0x000000010f8382c0
        frame #25: 0x000000010f833584
        frame #26: 0x000000010f8333f4
        frame #27: 0x000000010f833340
        frame #28: 0x000000010f8332dc
        frame #29: 0x000000010f85f044
        frame #30: 0x000000010f85ed18
        frame #31: 0x000000010f85e804
        frame #32: 0x000000010f85e360
        frame #33: 0x000000010f85e23c
        frame #34: 0x000000010f85dac0
        frame #35: 0x000000010f85d914
        frame #36: 0x000000010f85c730
        frame #37: 0x000000010f85bf7c
        frame #38: 0x000000010f1390d0
        frame #39: 0x000000010f162a78
        frame #40: 0x000000010e368304
        frame #41: 0x0000000104fbd9f8
        frame #42: 0x0000000104f94014
        frame #43: 0x0000000100deb774 libcoreclr.dylib`CallDescrWorkerInternal + 132
        frame #44: 0x0000000100c610f0 libcoreclr.dylib`DispatchCallSimple(unsigned long*, unsigned int, unsigned long, unsigned int) + 272
        frame #45: 0x0000000100c7580c libcoreclr.dylib`ThreadNative::KickOffThread_Worker(void*) + 148
        frame #46: 0x0000000100c2f52c libcoreclr.dylib`ManagedThreadBase_DispatchOuter(ManagedThreadCallState*) + 260
        frame #47: 0x0000000100c2fa98 libcoreclr.dylib`ManagedThreadBase::KickOff(void (*)(void*), void*) + 32
        frame #48: 0x0000000100c758e4 libcoreclr.dylib`ThreadNative::KickOffThread(void*) + 172
        frame #49: 0x0000000100b4d330 libcoreclr.dylib`CorUnix::CPalThread::ThreadEntry(void*) + 380
        frame #50: 0x000000018f2a3034 libsystem_pthread.dylib`_pthread_start + 136
    (lldb)
    
  19. gnattu commented on Oct 25, 2023

    @gnattu
    Author

    I'm a little bit confused because the thread stopped at different places in different runs:

    Run1:

    * thread #29, name = '.NET ThreadPool Worker', stop reason = signal SIGUSR1
        frame #0: 0x000000010f817860
    ->  0x10f817860: str    x0, [x29, #0x20]
        0x10f817864: ldr    x0, [x29, #0x20]
        0x10f817868: ldr    x1, [x29, #0x38]
        0x10f81786c: ldrh   w1, [x1]
    

    Run2:

    * thread #30, name = '.NET ThreadPool Worker', stop reason = signal SIGUSR1
        frame #0: 0x000000018f2660ac libsystem_kernel.dylib`__psynch_cvwait + 8
    libsystem_kernel.dylib`:
    ->  0x18f2660ac <+8>:  b.lo   0x18f2660cc               ; <+40>
        0x18f2660b0 <+12>: pacibsp
        0x18f2660b4 <+16>: stp    x29, x30, [sp, #-0x10]!
        0x18f2660b8 <+20>: mov    x29, sp
    

    Run3:

    * thread #41, name = '.NET ThreadPool Worker', stop reason = signal SIGUSR1
        frame #0: 0x0000000289c2a400
    ->  0x289c2a400: mov    x0, x19
        0x289c2a404: mov    x1, #0xe6d0
        0x289c2a408: movk   x1, #0x81cd, lsl #16
        0x289c2a40c: movk   x1, #0x2, lsl #32
    Target 0: (dotnet) stopped.
    
  20. kunalspathak commented on Oct 25, 2023

    @kunalspathak
    Contributor

    @kunalspathak I tried to get a backtrace using lldb but the backtrace does not show many useful data:

    Can you try gdb on linux/arm64? We need call stack of user thread, the ones you shared our from threadpool worker thread and are just waiting to receive the work.

  21. gnattu commented on Oct 25, 2023

    @gnattu
    Author

    Alright, I repeated using gdb on linux/arm64 with all the debug symbols downloaded:

    Thread 26 ".NET Tiered Com" received signal SIGSEGV, Segmentation fault.
    [Switching to Thread 0xffbeb6891160 (LWP 8449)]
    CodeGen::genHWIntrinsic (this=0xffbe9c1f0ea8, node=<optimized out>) at /__w/1/s/src/coreclr/jit/hwintrinsiccodegenarm64.cpp:379
    379	/__w/1/s/src/coreclr/jit/hwintrinsiccodegenarm64.cpp: No such file or directory.
    (gdb) bt
    #0  CodeGen::genHWIntrinsic (this=0xffbe9c1f0ea8, node=<optimized out>) at /__w/1/s/src/coreclr/jit/hwintrinsiccodegenarm64.cpp:379
    #1  0x0000ffff50172da0 in CodeGen::genCodeForBBlist (this=0xffbe9c1f0ea8) at /__w/1/s/src/coreclr/jit/codegenlinear.cpp:470
    #2  0x0000ffff50161508 in CodeGen::genGenerateMachineCode (this=0xffbe9c1f0ea8) at /__w/1/s/src/coreclr/jit/codegencommon.cpp:1918
    #3  0x0000ffff50169ff4 in CodeGenPhase::DoPhase (this=<optimized out>) at /__w/1/s/src/coreclr/jit/codegen.h:1785
    #4  0x0000ffff501604d0 in Phase::Run (this=0xffbeb688f710) at /__w/1/s/src/coreclr/jit/phase.cpp:61
    #5  DoPhase (_codeGen=0xffbe9c1f0ea8, _phase=PHASE_GENERATE_CODE, _action=<optimized out>)
        at /__w/1/s/src/coreclr/jit/codegen.h:1799
    #6  CodeGen::genGenerateCode (this=0xffbe9c1f0ea8, codePtr=<optimized out>, nativeSizeOfCode=<optimized out>)
        at /__w/1/s/src/coreclr/jit/codegencommon.cpp:1693
    #7  0x0000ffff501837f4 in Compiler::compCompile (this=0xffbe9c1f0558, methodCodePtr=0xffbeb688fcc8, methodCodeSize=0xffbeb688fe58,
        compileFlags=0xffbeb688fce0) at /__w/1/s/src/coreclr/jit/compiler.cpp:5102
    #8  Compiler::compCompileHelper (this=0xffbe9c1f0558, classPtr=<optimized out>, compHnd=<optimized out>,
        methodInfo=<optimized out>, methodCodePtr=<optimized out>, methodCodeSize=<optimized out>, compileFlags=<optimized out>)
        at /__w/1/s/src/coreclr/jit/compiler.cpp:6767
    #9  0x0000ffff50186944 in Compiler::compCompile(CORINFO_MODULE_STRUCT_*, void**, unsigned int*, JitFlags*)::$_11::operator()(Compiler::compCompile(CORINFO_MODULE_STRUCT_*, void**, unsigned int*, JitFlags*)::__JITParam*) const (this=<optimized out>,
        __JITpParam=<optimized out>) at /__w/1/s/src/coreclr/jit/compiler.cpp:5931
    #10 Compiler::compCompile (this=0xffbe9c1f0558, classPtr=0xffff5d75bd98, methodCodePtr=0xffbeb688fcc8,
        methodCodeSize=0xffbeb688fe58, compileFlags=0xffbeb688fce0) at /__w/1/s/src/coreclr/jit/compiler.cpp:5950
    #11 jitNativeCode(CORINFO_METHOD_STRUCT_*, CORINFO_MODULE_STRUCT_*, ICorJitInfo*, CORINFO_METHOD_INFO*, void**, unsigned int*, JitFlags*, void*)::$_13::operator()(jitNativeCode(CORINFO_METHOD_STRUCT_*, CORINFO_MODULE_STRUCT_*, ICorJitInfo*, CORINFO_METHOD_INFO*, void**, unsigned int*, JitFlags*, void*)::__JITParam*) const::{lambda(jitNativeCode(CORINFO_METHOD_STRUCT_*, CORINFO_MODULE_STRUCT_*, ICorJitInfo*, CORINFO_METHOD_INFO*, void**, unsigned int*, JitFlags*, void*)::$_13::operator()(jitNativeCode(CORINFO_METHOD_STRUCT_*, CORINFO_MODULE_STRUCT_*, ICorJitInfo*, CORINFO_METHOD_INFO*, void**, unsigned int*, JitFlags*, void*)::__JITParam*) const::__JITParam*)#1}::operator()(jitNativeCode(CORINFO_METHOD_STRUCT_*, CORINFO_MODULE_STRUCT_*, ICorJitInfo*, CORINFO_METHOD_INFO*, void**, unsigned int*, JitFlags*, void*)::$_13::operator()(jitNativeCode(CORINFO_METHOD_STRUCT_*, CORINFO_MODULE_STRUCT_*, ICorJitInfo*, CORINFO_METHOD_INFO*, void**, unsigned int*, JitFlags*, void*)::__JITParam*) const::__JITParam*) const (this=<optimized out>,
        __JITpParam=<optimized out>) at /__w/1/s/src/coreclr/jit/compiler.cpp:7413
    #12 jitNativeCode(CORINFO_METHOD_STRUCT_*, CORINFO_MODULE_STRUCT_*, ICorJitInfo*, CORINFO_METHOD_INFO*, void**, unsigned int*, JitFlags*, void*)::$_13::operator()(jitNativeCode(CORINFO_METHOD_STRUCT_*, CORINFO_MODULE_STRUCT_*, ICorJitInfo*, CORINFO_METHOD_INFO*, void**, unsigned int*, JitFlags*, void*)::__JITParam*) const (this=<optimized out>, __JITpParam=<optimized out>)
        at /__w/1/s/src/coreclr/jit/compiler.cpp:7438
    #13 jitNativeCode (methodHnd=<optimized out>, classPtr=<optimized out>, compHnd=<optimized out>, methodInfo=<optimized out>,
        methodCodePtr=<optimized out>, methodCodeSize=<optimized out>, compileFlags=<optimized out>, inlineInfoPtr=<optimized out>)
        at /__w/1/s/src/coreclr/jit/compiler.cpp:7440
    #14 0x0000ffff5018b198 in CILJit::compileMethod (this=<optimized out>, compHnd=0xffbeb688fe78, methodInfo=0xffbeb688ffb0,
        flags=<optimized out>, entryAddress=0xffbeb68900e0, nativeSizeOfCode=0x0) at /__w/1/s/src/coreclr/jit/ee_il_dll.cpp:261
    #15 0x0000ffff92fdb310 in invokeCompileMethodHelper (jitMgr=0xaaaafdd0cba0, comp=0xffbeb688fe78, info=0xffbeb688ffb0,
        jitFlags=..., nativeEntry=0xffbeb68900e0, nativeSizeOfCode=0xffbeb688fe58) at /__w/1/s/src/coreclr/vm/jitinterface.cpp:12331
    #16 0x0000ffff92fdb40c in invokeCompileMethod (jitMgr=0xaaaafdd0cba0, comp=0xffbeb688fe78, info=0xffbeb688ffb0, jitFlags=...,
        nativeEntry=0xffbeb68900e0, nativeSizeOfCode=0xffbeb688fe58) at /__w/1/s/src/coreclr/vm/jitinterface.cpp:12394
    #17 0x0000ffff92fdbe00 in UnsafeJitFunction (config=<optimized out>, ILHeader=0xffbeb68901b8, flags=...,
        pSizeOfCode=0xffbeb6890314) at /__w/1/s/src/coreclr/vm/jitinterface.cpp:12867
    #18 0x0000ffff93013a70 in MethodDesc::JitCompileCodeLocked (this=0xffff5d75f800, pConfig=0xffbeb68904a8, pEntry=0xffbeac12c860,
        pSizeOfCode=0xffbeb6890314, pFlags=0xffbeb6890300) at /__w/1/s/src/coreclr/vm/prestub.cpp:952
    #19 0x0000ffff93013724 in MethodDesc::JitCompileCodeLockedEventWrapper (this=0xffff5d75f800, pConfig=0xffbeb68904a8,
        pEntry=0xffbeac12c860) at /__w/1/s/src/coreclr/vm/prestub.cpp:823
    #20 0x0000ffff93012f90 in MethodDesc::JitCompileCode (this=0xffff5d75f800, pConfig=0xffbeb68904a8)
        at /__w/1/s/src/coreclr/vm/prestub.cpp:763
    #21 0x0000ffff93012b38 in MethodDesc::PrepareILBasedCode (this=0xffff5d75f800, pConfig=0xffbeb68904a8)
        at /__w/1/s/src/coreclr/vm/prestub.cpp:426
    #22 0x0000ffff930436d8 in TieredCompilationManager::CompileCodeVersion (this=<optimized out>, nativeCodeVersion=...)
        at /__w/1/s/src/coreclr/vm/tieredcompilation.cpp:907
    #23 0x0000ffff93042cc4 in TieredCompilationManager::OptimizeMethod (this=0xaaaafdddeea8, nativeCodeVersion=...)
        at /__w/1/s/src/coreclr/vm/tieredcompilation.cpp:884

    Now it looks like it is from a very similar cause in #93912.

  22. kunalspathak commented on Oct 25, 2023

    @kunalspathak
    Contributor

    Now it looks like it is from a very similar cause in #93912.

    Yep, it is.

  23. ghost added
    in-pr
    on Oct 25, 2023
  24. kunalspathak commented on Oct 25, 2023

    @kunalspathak
    Contributor

    @gnattu - I have submitted #93983, but wondering if upgrading to .NET8 an option for you?

  25. ghost removed
    in-pr
    on Oct 25, 2023
  26. gnattu commented on Oct 26, 2023

    @gnattu
    Author

    No, upgrading to .NET 8 requires more effort than we can currently undertake. I downloaded the artifacts from Azure Pipeline in #93992 and overwrote the libcoreclr and libclrjit. I confirmed that Jellyfin no longer crashes.

  27. ghost locked as resolved and limited conversation to collaborators on Nov 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area-CodeGen-coreclr

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions