PhysX Crash

I have a crash occurring sometimes, but it’s absolutely not reproducable and is not happening too often.

This is log:

[2015.05.27-23.20.44:798][585]LogCrashTracker: 


[2015.05.27-23.20.44:798][585]LogThreadingWindows:Error: Runnable thread TaskGraphThread 3 crashed.
[2015.05.27-23.20.44:798][585]LogCrashTracker: 


[2015.05.27-23.20.44:798][585]LogWindows: === Critical error: ===
Fatal error!

Unhandled Exception: EXCEPTION_ACCESS_VIOLATION reading address 0x00000010

PhysX3PROFILE_x64.dll!UnknownFunction (0x000007fed0935210) + 0 bytes [UnknownFile:0]
PhysX3PROFILE_x64.dll!UnknownFunction (0x000007fed08f0e96) + 0 bytes [UnknownFile:0]
PhysX3PROFILE_x64.dll!UnknownFunction (0x000007fed08f81d8) + 0 bytes [UnknownFile:0]
PhysX3PROFILE_x64.dll!UnknownFunction (0x000007fed07964e2) + 0 bytes [UnknownFile:0]
UE4Editor-Engine.dll!TGraphTask<FPhysXTask>::ExecuteTask() (0x000007fed77ddcd1) + 0 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.7\engine\source\runtime\core\public\async\taskgraphinterfaces.h:671]
UE4Editor-Core.dll!FTaskThread::ProcessTasks() (0x000007feda324fa5) + 0 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.7\engine\source\runtime\core\private\async\taskgraph.cpp:428]
UE4Editor-Core.dll!FTaskThread::ProcessTasksUntilQuit() (0x000007feda32518d) + 0 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.7\engine\source\runtime\core\private\async\taskgraph.cpp:271]
UE4Editor-Core.dll!FTaskThread::Run() (0x000007feda3339cb) + 0 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.7\engine\source\runtime\core\private\async\taskgraph.cpp:562]
UE4Editor-Core.dll!FRunnableThreadWin::Run() (0x000007feda587346) + 0 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.7\engine\source\runtime\core\private\windows\windowsrunnablethread.cpp:73]
UE4Editor-Core.dll!FRunnableThreadWin::GuardedRun() (0x000007feda57c32d) + 8 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.7\engine\source\runtime\core\private\windows\windowsrunnablethread.cpp:26]
kernel32.dll!UnknownFunction (0x00000000775659cd) + 0 bytes [UnknownFile:0]
ntdll.dll!UnknownFunction (0x000000007769b981) + 0 bytes [UnknownFile:0]
ntdll.dll!UnknownFunction (0x000000007769b981) + 0 bytes [UnknownFile:0]

Crash in runnable thread TaskGraphThread 3

[2015.05.27-23.20.45:071][585]LogExit: Executing StaticShutdownAfterError
[2015.05.27-23.20.45:071][585]LogWindows:Error: Error reentered: Runnable thread TaskGraphThread 3 crashed.
[2015.05.27-23.20.45:071][585]LogWindows:Error: HandleError re-entered.
[2015.05.27-23.20.45:071][585]LogWindows: FPlatformMisc::RequestExit(1)
[2015.05.27-23.20.45:071][585]Log file closed, 05/28/15 01:20:45

And this is what CrashReported says:

MachineId:C093024B4F8D72EA90A2EBB7201E91B6
EpicAccountId:02d0ec4128004fd98b3c89b8afc7933d

Access violation - code c0000005 (first/second chance not available)

PhysX3PROFILE_x64 + 2773520 bytes
PhysX3PROFILE_x64 + 2494102 bytes
PhysX3PROFILE_x64 + 2523608 bytes
PhysX3PROFILE_x64 + 1074402 bytes
UE4Editor_Engine!TGraphTask<FPhysXTask>::ExecuteTask() + 449 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.7\engine\source\runtime\core\public\async\taskgraphinterfaces.h:671]
UE4Editor_Core!FTaskThread::ProcessTasks() + 3125 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.7\engine\source\runtime\core\private\async\taskgraph.cpp:428]
UE4Editor_Core!FTaskThread::ProcessTasksUntilQuit() + 77 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.7\engine\source\runtime\core\private\async\taskgraph.cpp:271]
UE4Editor_Core!FTaskThread::Run() + 11 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.7\engine\source\runtime\core\private\async\taskgraph.cpp:562]
UE4Editor_Core!FRunnableThreadWin::Run() + 102 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.7\engine\source\runtime\core\private\windows\windowsrunnablethread.cpp:73]
UE4Editor_Core!FRunnableThreadWin::GuardedRun() + 93 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.7\engine\source\runtime\core\private\windows\windowsrunnablethread.cpp:26]
kernel32 + 88525 bytes
ntdll + 178561 bytes

It’s really not happening too often, I got this crash for 6 or 7 times in total now, every few days. It’s mostly happening while spawning an Instanced Static Mesh Component, or spawning an Actor which has an Instanced Static Mesh Component inside, or adding an Instance to an Instanced Static Mesh Component. Not completely sure. Because this is all happening together in my game.

game just freezes, and then after like 10 seconds freeze UE4 gets closed and Crash Reporter shows up.

And it’s not reproducible, I do same thing in my game dozens of times each day and nothing crashes. So I also can’t really try whether it still occurs in 4.8.

Hey ,

Unfortunately unless we have some way of reproducing crash on our end, it will be incredibly hard to track down where crash is occurring so we can find a fix for issue. If there is a blueprint or a set up you believe will reproduce crash in an empty project we can take that and work from there. Thank you for taking time to create report.

Regards,

Hi Andrew,

I know it’s really hard for you to fix this without having repro steps, but it’s not reproducible so I will never be able to give you anything which would reproduce this.
Couldn’t you just take a look into code where crash occurs and see what there could cause an “Access Violation”?

If you would like to send us bare minimum of project to test, that would be helpful, but aside from that simply looking at log does not provide enough information.

Hey ,

I was just notified of a bug report that was generated from a similar crash you are experiencing, and as you mentioned on here as well as noted in report, repro is hard to come by. However, since bug report has already been made for this issue, if you have a test project in which you can provide that has had issue occur, send that to me so I can attempt to get repro on my end.

Thank you,

Hi Andrew, unfortunately I don’t have a test project for this. As I said this bug is happening not really often, so I would have to use a test project for like 3 days to one week until I would know whether bug occurs there or not.
I think only possible way to fix this bug is to look at code where editor is crashing and see what there could cause an Access Violation, I thought information in callstack (PhysX3PROFILE_x64 + 2773520 bytes) is basically saying in which code line crash occurs?

Unfortunately crash still occurs in 4.8.

I get this crash (or a similar one) really often now… And after crash UE4 does not even close, it just stays opened. So I see crash reporter, click on “send and restart”, project opens again, but old crashed one just stays opened, but is freezed. And I only see half of callstack in log because engine seems to crash before its able to fully write in log. Were there any fixes for crashes like this in last months added to master branch?

Hey ,

I am looking at your most recent crash now, and if you could please provide me with some way to reproduce this issue on my end. What is it in this project that is using Nvidia PhysX and roughly what are you usually doing when this crash occurs?

Hi Andrew, thanks, I am just adding and removing instances to instanced static meshes and tracing a lot for instances while I add and remove instances… So I don’t really use any physics stuff, except that instances of course have collision. I’ve tried to reproduce it in a new project, but I can’t. I have also tried it in promoted branch, crashes there too.

Would you mind showing me this process or providing me with some type of test case so I can get it to occur on my end?

I guess sending you project is only way to show you crash…
Will sent you a PM in forums with download link.

Hey ,

There must me some corruption somewhere within your project which is causing issues. I cannot test project because as soon as I press play it freezes. I also attempted to open Wall blueprint asset you mentioned, and it also freezes up my editor.

Also, I noticed you have a destructible mesh within engine which is going to be using PhysX. This could be cause or focus of why your project is crashing. You said you cannot reproduce this in a blank project, which means it is specific to what you have established in this project. At this point even if I were to enter a bug with crash logs you have provided attached, it would have not direction as there is no logical steps to follow in order to reproduce crash. We need these steps to help us determine cause of issue and where to address fix.

Perhaps try resending project with absolute bare minimum assets. I only need your Config, Content, and Uproject files zipped into folder.

Regards,

Hi Andrew, thanks, but please try again. I know first time you start up editor hitting play will need 1 to 3 minutes until game starts, but that’s usual. If you then stop game and hit play again it starts immediately, it’s just because on first hitting play editor compiles all blueprints which takes some time. crash is very reproducible, just do steps I send you in PM.
If you just need Config, Content and uproject files you can just delete other folders, but then you will first have to wait 2 or 3 hours on first startup because it will need to compile all shaders then… So I thought its better to send you project including all folders.

Hey ,

I have entered a bug report for this issue after successfully reproducing crash. issue is UE18808 and I cannot currently say when this will be addressed and fixed. Thank you for report and your patience during reporting process.

Regards,

Great, thanks!

Hey Andrew, could you give me any update on this? Is it fixed in 4.9? I can’t find UE-18808 in known issues list for 4.9, but I guess that does not automatically mean that it’s fixed.

This has been marked for 4.10 and has not been addressed as fixed as of late.

Oh, is there any reason written why not for 4.9? I thought for you at Epic fixing bugs which lead to crashes has highest possible priority?

issue was not effecting enough users to gain highest priority. This doesn’t mean we have ignored it, as it is marked for 4.10.