Thứ Ba, 12 tháng 11, 2013

Tuesday Treaker

Aha!

The sound of victory, perhaps, the sound of a small mystery uncovered, definitely. You will be disenchanted to learn I was not working on performance today. I was working on that annoying horrible vertex corruption we have been seeing in the gun and characters.  You will NEVER guess what I found inside my engine source code:

// sort into time ascending order at init stage
// very time consuming - so skip until see adverse affects!

//if ( pAnim ) SortAnimationDataByTime ( pAnim );

Amazing or what!  I must have been insanely tired or blind to comment this function out, not provide a date, to even think that I could get away with it and finally to lose all trace of every doing it and carrying on with my day.

I have not actually uncommented and compiled yet but I would bet a pint of Guinness that this is the bug. I vaguely remember removing this line to speed up character loading, madness!!

Other News

As yesterday's blog was a little small, I want to report on what happened on Monday in a little more detail. My PC decided to corrupt one file (just one) at the I/O level, which means a PHYSICAL hole in my data. All the usual suspects such as CHKSDK, Defrag, rename, remove and rebel where all in vain. I left the PC to do a full defrag overnight in the hopes it would move the offending file to some new sector which did not have a hole.  No joy.  First thing today I renamed my SVN repository, moved all the files over and left that one file in the old location locked and alone.  It's such a dangerous file that even if I cursor over it Windows File Explorer will crash!

As this is hardly a professional status quo, I have ordered a new replacement 128GB SSD drive and will have the miserable job of a full Windows re-install sometime this week. The good news is that the new drive is much faster than the old one and starting Windows a fresh always provides a nice fast OS (at least to begin with) to enjoy for a few months.  It arrives Wednesday, so that will probably be the day.

My Mission

I decided my mission for today was to either fix the vertex corruption or make the engine faster. Having tried reducing the shaders and noticing almost no performance improvement on my 650 Ti Boost (likely due to being CPU bound rather than GPU), and also failing to get the NSIGHT tool to do anything practical (after re-installing drivers, updating the tool, changing my WDD settings, fiddling with configurations and ultimately getting absolutely nothing from my attempt to profile my frames) I finally got to the line of code you saw above, which means in theory I have achieved something today!

Signing Off

A meeting was held today in other parts of TGC land, and it was agreed by all that performance and key bug fixes are to remain our top priority, and this attitude will continue until we have a solid and fast architecture.  I am the first to leap up and down when new features are busting to be coded, but I am also a realist, and I learn from my past mistakes, and unless we get the core of the engine correct there is little point in adding pretty tinsel over it.  

So today, we 'maybe' fix the animating corruption issue, tommorow I fix my HDD corruption issue and Thursday I dive headlong into shadow batching, which I can confidently predict will give me a 10fps speed up, which when you consider going from 26fps to 35fps, that's a substantial performance boost!

Không có nhận xét nào:

Đăng nhận xét