User Tag List

Results 1 to 8 of 8

Thread: Has anyone made a performance profiler?

  1. #1
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Fusion 2.5+ DLC (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Volnaiskra's Avatar
    Join Date
    Jan 2014
    Location
    www.sprykegame.com
    Posts
    2,558
    Mentioned
    133 Post(s)
    Tagged
    0 Thread(s)

    Has anyone made a performance profiler?

    Has anyone made some kind of performance profiler for Fusion?

    By performance profiler, I mean something that will measure how long different parts of your code are taking to execute. And possibly measuring other parts of the runtime, like how long drawing objects is taking, which objects are the most cpu/GPU intensive, and so on. The main goal is to find evidence of the greatest bottlenecks in a game, without relying on guesswork and speculation.

    If someone's built something like this in their own game, could you please share your code, or explain how you did it? And if not, does anyone have any ideas about how to implement something like this?

  2. #2
    Forum Moderator

    Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleUniversal Windows Platform Export ModuleSWF Export ModuleXNA Export ModuleInstall Creator Pro
    nivram's Avatar
    Join Date
    Jul 2006
    Location
    Bandon, Oregon
    Posts
    6,773
    Mentioned
    12 Post(s)
    Tagged
    0 Thread(s)
    Tis a pity, because 1.5 and TGF had a step through editor that was great for this kind of thing. Sorry I don't have information to help out. This would be a great application to have.

    Marv
    ​458 TGF to CTF 2.5+ Examples and games
    http://www.castles-of-britain.com/mmf2examples.htm

  3. #3
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export Module
    Fusion 2.5 (Steam)
    schrodinger's Avatar
    Join Date
    Nov 2014
    Posts
    3,159
    Mentioned
    28 Post(s)
    Tagged
    1 Thread(s)
    Only for the graphics-GPU side:
    I have an intel graphics card and use GPA which is very nice,
    I use it to debug shaders output, as it can output "frame snapshots" of compiled hlsl shaders,
    so didn't really check in depth what else it can do
    (though I saw it clearly states how many μs each drawing function takes, for each texture,
    and has lots of graphing for various CPU and GPU profiling etc.)

    https://software.intel.com/en-us/gpa

    Screenshot of system analyzer (to the left various tasks you can monitor)




    and in-app HUD, this HUD pops out in the app you select to analyze
    and provides the commands to send "snapshots" of a frame to the other more in-depth tools of the suite:



    You don't probably have an Intel graphics card, and I *guess* it only works on intel cards,
    but I remember seeing other similar tools when I was looking for this one,
    so perhaps you can find something for your specific card
    (I remember hearing of "PIX" from Microsoft, not sure it does all that profiling, didn't try it because doesn't work on Win7)

  4. #4
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Fusion 2.5+ DLC (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Volnaiskra's Avatar
    Join Date
    Jan 2014
    Location
    www.sprykegame.com
    Posts
    2,558
    Mentioned
    133 Post(s)
    Tagged
    0 Thread(s)
    Thanks. It appears to work with Nvidia cards also. I got it running and exported some frame and trace files, and opened them with the Graphics Frame Analyzer and Platform Analyzer tools. The tools look impressive, but also like absolute gibberish to me Do you have any idea what I should be looking at?




  5. #5
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Fusion 2.5+ DLC (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Volnaiskra's Avatar
    Join Date
    Jan 2014
    Location
    www.sprykegame.com
    Posts
    2,558
    Mentioned
    133 Post(s)
    Tagged
    0 Thread(s)
    I just tried to time certain sections of my code, by recording the timer before a chunk of code, and then again after it. But it seems that Fusion's timer only ever gives you one value per frame. In other words, no matter where in my code I recorded the timer (the very first event, the very last event, somewhere in the middle...) it returned exactly the same timer value. It seems you can measure how long something takes between one frame and the next, but you can't measure how long something takes within the frame.

    Can anyone think of a way to get around this issue, and successfully measure the time elapsed between different parts of your code?

  6. #6
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export Module
    Fusion 2.5 (Steam)
    schrodinger's Avatar
    Join Date
    Nov 2014
    Posts
    3,159
    Mentioned
    28 Post(s)
    Tagged
    1 Thread(s)
    for GPA: not really , as I said I only used it to debug a shader, so not delved in the other features much
    (never opened the Platform Analyzer actually )

    I've seen (again, for the shader) it indicated the exact time each operation of the shader took to perform,
    so since we can modify shaders, we can operate there to improve performance.
    But for the rest, I doubt we have enough control to make anything else than look at those graphs in despair
    (beside of course optimizing the things we already know how to optimize..)
    or perhaps look at "where" it's more relevant to optimize, probably this tool might give some hint on that..


    For your latest post, you could use the computer clock >> date and time object
    (i.e. add hundreds of seconds to a list object before and after the chunk of code)
    hs is not very sensible, I think the only chance of making it more sensible is iterating over and over the chunk of code (>> every event) in a fastloop,
    so it becomes more widely measurable ...very uncomfortable to do on big chunks of code though!

  7. #7
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Fusion 2.5+ DLC (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Volnaiskra's Avatar
    Join Date
    Jan 2014
    Location
    www.sprykegame.com
    Posts
    2,558
    Mentioned
    133 Post(s)
    Tagged
    0 Thread(s)
    Ah, thanks. Yes, the Date & Time Object does work for this. Unfortunately, hundredths of a second is too coarse to be of any use (even milliseconds would arguably be too coarse). When I measure the hundreths of a second that ALL of my code takes to complete, the result is: usually 0, sometimes 1. That's not very helpful if I want to measure little portions of that code

    I think useful measurements of time taken of bits of code are going to be impossible without some sort of third party tool or extension. Does anyone know if an extension that provided a microseconds-based timer would be easy to make?

  8. #8
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Fusion 2.5+ DLC (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Volnaiskra's Avatar
    Join Date
    Jan 2014
    Location
    www.sprykegame.com
    Posts
    2,558
    Mentioned
    133 Post(s)
    Tagged
    0 Thread(s)
    OK, for the benefit of future visitors to this thread (how are those flying cars coming along?), I can let you know that a profiler of sorts now exists. I took matters into my own hands (sort of) and built one myself.

    To address the problem of not being able to measure beyond hundredths of a second within the frame (or in milliseconds between frames), I commissioned Looki to make a new extension that measures within the frame in microseconds. It's called Microtimer, and you can get it for free here. Using Microtimer, I then built an easy-to-use in-game profiler called volPROFILER. It won't measure GPU stuff, but it's very useful for measuring the performance of your code. It's shown in the GIF below. You can get volPROFILER for 2.99 on the Clickstore here.




Similar Threads

  1. Performance better on SWF than PC
    By EdibleWare in forum Lacewing
    Replies: 7
    Last Post: 14th July 2015, 10:22 PM
  2. News about profiler for fusion
    By pit73 in forum HTML5 Export Module 2.5
    Replies: 13
    Last Post: 10th February 2015, 03:30 PM
  3. Why is iOS performance so poor?
    By ratty in forum iOS Export Module Version 2.0
    Replies: 9
    Last Post: 29th June 2013, 02:43 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •