Terms of Service
Demos & Libraries
Tutorials & Snippets
Art & Sound
Contests & Events
Webclient FPS issues
Aug 31 2015, 8:53 am
Yes, Timsort should be trivial to change there because I've already implemented it.
Aug 31 2015, 12:10 pm
All testers once again used Chrome, though I didn't check to see if FPS is as bad on other browsers... but I'm assuming it is based on the past cases. FPS also drops considerably during heavy animation instances, such as PvE where there's multiple mobs and spell effects.
Tester #5 -
Tester #6 -
Tester #7 -
Tester #8 -
Tester #9 -
Aug 31 2015, 12:39 pm
Interesting results, although I think tester #6 is a write-off. Windows 10 with 2 GB of RAM? Good gads.
Aug 31 2015, 12:57 pm
I took the liberty of doing some profiling. I'll PM you a copy of the profiling data from chrome during one of the heavy phases. It's pointing mostly to unoptimized methods due to several functions constantly trying to re-optimize due to "optimized too many times" errors:
There are also a lot of optimization warnings here and there:
The good news is that this is definitely a scripting issue, which means with some work, it should be doable to fix.
Aug 31 2015, 1:12 pm
Very interesting! (I'm also curious how you managed to profile the code. I haven't been able to find good info on that.)
What I hope is that a number of the functions involved are something that I can fix. Because the webclient is compiled from Dart in Dart2js, I don't have direct control over most of the JS code. But I suspect there are a lot of functions where this isn't a big deal.
Aug 31 2015, 1:14 pm
Chrome comes with a code inspector. It's really great.
Aug 31 2015, 2:09 pm
I think I found one of the big culprits: AtomInfo.animating() had a call to List.firstWhere() that I think was freaking it out. If I'm reading my new results right, that's no longer the case in my modified code.
Combing through this JSON is kind of brutal so it might be hard to identify more cases (plus some are on common funtions that are hard to weed out, like I notice JsLinkedHashMap.$index has that issue), but I'll see what else I can find if any.
Aug 31 2015, 3:53 pm
I went ahead and released without trying Timsort, the main reasons being 1) I'm not convinced my Timsort implementation wouldn't be more of the same issue, 2) sorting seems to be only a small factor, and 3) I'd like to reduce the number of variables while tracking improvements.
508.1299 is the new public release, but the webclient is still considered a beta feature and will continue to be worked on in the upcoming 509 beta builds.
Aug 31 2015, 6:38 pm
With the new version, immediately after firing game up:
After a couple minutes of combat / playtesting:
Aug 31 2015, 7:44 pm
How does that compare to your earlier tests on the same machine?
Aug 31 2015, 8:00 pm
I think this was on the same machine:
The degradation over time is new to me though. Did FPS return to 40/60 when you moved back to the spawn without any PvE, or did it stay at 15/20 regardless? The testers also noticed a FPS drop during PvE, but I assumed this was natural since there's more going on in the screen. FPS was better in areas with less, such as small sized interior where there's a fair amount of black space on-screen.
Aug 31 2015, 9:51 pm
I have a hunch that maybe some atoms are staying alive longer than intended, and that could be causing the degradation. I'll have to run some tests myself.
If anyone else wants to also run some profiling, having more results to comb through would be a big help. I'm most interested in routines that aren't optimizing well, and what I can do to fix that.
Sep 22 2015, 9:51 pm
Here's a profile snapshot of the latest
BYOND release: (It's raw JSON but if you open it with the chrome profiler it'll arrange it in something more legible)
Performance seems to be increasing with the passing releases but it's still not anywhere we'd like it to be.
Sep 23 2015, 9:17 pm
Sep 29 2015, 5:01 pm
In the latest version there's a big improvement, with my FPS now at 20-25, after originally being at 6-10. Still not up to par with DS, mind, but definitely a step in the right direction.
Sep 29 2015, 6:08 pm
Glad to hear it!
Sep 30 2015, 2:11 pm
I forgot to add this, but if you can get new profiler data on the updated version, that'd be terrific. The more data the better!
Oct 3 2015, 9:13 pm
CPU profile for build 509.1303. Let me know if anything else needs clarifying.
Oct 15 2015, 8:09 pm
How's this going?
Oct 15 2015, 8:14 pm
I worked a little on the data I got from 1303, but please keep the reports coming. More profile data is always good.
Copyright © 2019 BYOND Software. All rights reserved.
Terms of Service