Announcement

Collapse
No announcement yet.

Tips to track down fatal errors?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Tips to track down fatal errors?

    For a long time I've had occasional crashes in my game. The logs don't seem to give me any indication of what actually happened:

    Code:
    [0054.68] Log: === Critical error: ===
    Fatal error!
    
    Address = 0x3fec7e3f (filename not found) [in C:\Program Files (x86)\UDK\Binaries\Win64\UDK.exe]
    Address = 0x3fec8e52 (filename not found) [in C:\Program Files (x86)\UDK\Binaries\Win64\UDK.exe]
    Address = 0x4033b21e (filename not found) [in C:\Program Files (x86)\UDK\Binaries\Win64\UDK.exe]
    Address = 0x4035766c (filename not found) [in C:\Program Files (x86)\UDK\Binaries\Win64\UDK.exe]
    Address = 0x402b1856 (filename not found) [in C:\Program Files (x86)\UDK\Binaries\Win64\UDK.exe]
    Address = 0x4132ff46 (filename not found) [in C:\Program Files (x86)\UDK\Binaries\Win64\UDK.exe]
    Address = 0x41334b5c (filename not found) [in C:\Program Files (x86)\UDK\Binaries\Win64\UDK.exe]
    Address = 0x41334bda (filename not found) [in C:\Program Files (x86)\UDK\Binaries\Win64\UDK.exe]
    Address = 0xe6a119c2 (filename not found) [in C:\Windows\Microsoft.NET\Framework64\v4.0.30319\clr.dll]
    Address = 0x1e8171   (filename not found) 
    Address = 0x5        (filename not found) 
    Address = 0x3fc80000 (filename not found) [in C:\Program Files (x86)\UDK\Binaries\Win64\UDK.exe]
    Address = 0x3fa14a0  (filename not found) 
    Address = 0xe6a45269 (filename not found) [in C:\Windows\Microsoft.NET\Framework64\v4.0.30319\clr.dll]
    Address = 0x5        (filename not found) 
    Address = 0x66e590   (filename not found) 
    Address = 0x66e590   (filename not found)
    It is fairly rare that these crashes occur, but I still desperately want to figure out what is happening. Does anyone know of any tools, etc that may help my figure out what might be causing these crashes?

    Is there anyway for me to inspect the .dmp files in the logs? I'm assuming these are crash dumps.

    Any suggestions would be much appreciated

    #2
    just backtracking until you find the cause.this wont help too much though if you've left the problem for a while as you will have probably done far to much to remember everything.

    when you get a crash,do your best to sort it before going any further.

    other than that I know of no tools,im afraid.

    and yes,the logs are next to useless sometimes.

    Comment


      #3
      I could be wrong, but dmp files are also useless

      like gaz says it's best to backtrack and for that it's best to fix it as soon as you see it.
      but if you're past that point (and since there's really no tools) the best you can do would be this:
      - identify what was going on in general when the crash appeared
      - find reliable reproduction steps to the crash
      - isolate different elements of your game (i.e. remove AIs from your level, try an empty level, etc) until you find the element that causes the crash
      - go deeper into it: if it's code then comment out portions of it, if it's some actor property try switching them around, etc

      a while ago this happened to me and I isolated the problem: enabling UseCompartment in certain actors (either for Cloth or Physics, can't remember) would cause crashes in only a few computers (but not in mine), but when I upgraded my GPU it also started happening to me. then I followed the above procedure which led me to fixing it

      Comment


        #4
        My experience with UDK 4 years+ what most errors come from: " And the only ones i had "

        Errors:

        1- Hitmask, it eats your graphics card memory, " Ran out of memory thing "

        2- Infiinite loop with the For, and whiles, " the loops".

        3- The AI state loop, Begin: most came from there"

        4- Changing the map without removing all actors game Info lol hacky way to get rid of errors.... And forcing grabage collection after deleting all of them.


        Performance:

        What most ate the performance:

        1- Pawns, Modular pawn with too much components,

        2- IK inverse kinematics, " UpdateKinematicSetTo 0.9 " , makes it get updated only 100 From camera. SkeletalMesh:VariableThingy....

        3 - TurnOff() Pawn function native call, to turn off physics or anything running on a pawn, " awsome for pawns that are supsoed to be dead "

        Best Debugging Practises:

        1 - Add postRendered textes upon pawns to display their health individually and other occasional variables. " Means textes and vars upon em "

        2 - All the commands of UDK to see traces and such are very usefule to.

        3 - Set all structs on one file upon all other classes GameAllStructs GamePawn, pawn sees all structs now, don't use dependsOn it is so hard to use it well....

        4- Add a Log("FROM Class GamePawn FunctionName() This is what happend " ) , some protocol like that works awsomely to track game state from log.



        Hope my expeirience helps on both performance and error solving and deubugging practises, to solve your actual errors or to solve your future errors.

        Comment


          #5
          in my experience,and I may be wrong,but all the code you posted about address not found is stuff that happens after the crash and is therefore irrelevant.

          its the last line before [0054.68] Log: === Critical error: === that will give the best clue.

          Comment


            #6
            #1. Using slomo and the remote control feature can help sometimes...
            https://forums.epicgames.com/threads...ighlight=debug

            #2. Spoof's`trace, an alternative to `log is worth looking at too:
            https://forums.epicgames.com/threads...rnative-to-log

            #3. And this:
            https://forums.epicgames.com/threads...1#post31709230

            But overall when you can't just debug something by loading symbols and setting breakpoints, you have to custom log everything verbose and switch on/off sections to narrow the field as Chosker / Gaz661 said.

            Comment


              #7
              Thanks for the responses guys. Unfortunately the crash usually doesn't occur until after several hours of stable gameplay. There also doesn't appear to be any obvious pattern of events that lead up to it.

              I think the .dmp files contain a snapshot of the system at the time of the crash, including a stack-trace. But I'm not sure of what tools to use to inspect it. I've seen other big UDK projects (like Chivalry) whereby they request players send them the .dmp files when experiencing crashes, so they must be useful.

              Comment


                #8
                Originally posted by coldscooter View Post
                doesn't occur until after several hours of stable gameplay. There also doesn't appear to be any obvious pattern of events that lead up to it.
                The prob may be resources: memory / obj-handles related. The obvious one to check first is memory. In the Feb 2013 of UDK, Movable lights often lead to mem leaks etc. Handles can be checked using monitoring tools like ProcExp / ProcMon (Sysinternals / Depends) or other profilers.

                Originally posted by coldscooter View Post
                I think the .dmp files contain a snapshot of the system at the time of the crash, including a stack-trace. But I'm not sure of what tools to use to inspect it. I've seen other big UDK projects (like Chivalry) whereby they request players send them the .dmp files when experiencing crashes, so they must be useful.
                You can open the dumps in MS Debugging Tools for Windows and it will tell you the module at fault, but its probably too broad. You usually need symbols to decrypt it (which us Indies don't have), otherwise its just a bunch of assembler and hex. Ideally what you want is to get access to the symbols for UDK, then you can 'attach to process' and debug it 'live'. Maybe some of the old code pros like UnrealEverything, RattleSN4K3, Spoof, Jetfire, etc are still around to chip in or would respond to a PM.

                Comment


                  #9
                  Check this https://forums.epicgames.com/threads...t-clr-dll-quot

                  Also if its in PIE then I'd suggest create a package and install a game as PIE can do things that don't occur normally

                  Comment


                    #10
                    Unfortunately I don't have any better suggestions to those already mentioned. Since you said it only crashes after some time it could very well be a memory leak. The problem is to figure out whether it's your own fault, caused by your code, or a bug in the engine itself. If it's the second then you're officially screwed unless you can test with another UDK version.
                    One way to follow the execution of code is the profiler that comes with the engine. If I recall correctly it contains some (maybe even all) of the native call stack. The only issue is that these profiling files can quickly get very large.
                    Are you using -forcelogflush as well in the commandline to make sure all log is written everytime even in cases of crashes?

                    @yummy-vegetables: I've seen cases where PIE worked fine but an (installed) game would crash, but it's a good hint anyway that this could make a difference as well.


                    One of the reasons I have more or less switched to UE4 is that you have full source code access. Whenever the engine crashes it gives you the stack trace along with any error messages like failed assertions, exceptions, etc. (most of the time anyway unless you've really screwed up ). And of course you can step through the code and debug it and even change and fix it yourself should you encounter something going wrong in the engine. I'm still keeping an eye on this forum as well though.

                    Comment


                      #11
                      Thanks for the input @UnrealEverything. I didn't know about -forcelogflush, so I will definitely add that, as I notice that a lot of times the logs will cut-off during crash, so that may help. I haven't used the profiler at all, so I will also look into that. Thanks again.

                      Comment


                        #12
                        I have started to notice a pattern regarding these crashes: The game will play fine for several hours, then the crash will occur. After booting the game back up, the crash will occur very soon, and continue to occur fairly quickly each time, until I restart the computer. After restarting the computer I can play again for several hours before the crash happens.

                        Does this highlight anything for anyone that may help me track this down?

                        Comment


                          #13
                          Originally posted by coldscooter View Post
                          Does this highlight anything for anyone that may help me track this down?
                          Which OS? ... This is often indicative of precious system resources / handles that haven't been released.
                          The Sysinternals tools suite (procmon / procexp etc) may help if you can't find the cause directly in UDK.

                          Comment

                          Working...
                          X