Natural Selection 2
Login Now >
Click here to create a new account
Unknown Worlds Entertainment
Home
Game Guide
Community
Media
Forums
Store
Twitter
Facebook
YouTube
Latest Developer Posts
Promoted Content
Insane
Anomaly
1:19PM
help with spark editor
Check that your map has all of the following entities: - ns2_gamerules - pathing_settings - location entities for all the areas you want to have power.
matso
Master of Patches
May 23
Do the "Performance-Jam"!!!
Insane wrote: » ezekel wrote: » Scatter wrote: » Is LuaJIT something that must be implemented game wide or can it be used in certain critical pathways? I have a basic coding understanding but not enough to really know this off hand. I think luaJIT splits the workload, so one part of the game goes through luaJIT, then another part goes through regular lua.. so making the work more evenly split on the cores already supported or I'm an idiot and you can just disregard what I said because it's a complete guess Not quite. In very simple terms, LuaJIT translates Lua code into a format that your CPU can read more quickly. It does this just before the code segment is actually executed, hence the name (Just In Time). Turns out that Wikepedia has a very nice article how a tracing JIT compiler like LuaJIT actually works ... https://en.wikipedia.org/wiki/Tracing_just-in-time_compilation
Insane
Anomaly
May 23
Do the "Performance-Jam"!!!
ezekel wrote: » Scatter wrote: » Is LuaJIT something that must be implemented game wide or can it be used in certain critical pathways? I have a basic coding understanding but not enough to really know this off hand. I think luaJIT splits the workload, so one part of the game goes through luaJIT, then another part goes through regular lua.. so making the work more evenly split on the cores already supported or I'm an idiot and you can just disregard what I said because it's a complete guess Not quite. In very simple terms, LuaJIT translates Lua code into a format that your CPU can read more quickly. It does this just before the code segment is actually executed, hence the name (Just In Time).
Sewlek
The programmer previously known as Schimmel
May 23
Sewlek's Balance mod
CrazyEddie wrote: » BigRustyRed wrote: » RT's felt less important so the focus was a lot more on attacking specific areas of the map and holding map control then chasing after recappers and defending RTs. I haven't played the BT mod yet, but what you've described sounds like a good change to me. I get tired of constantly hearing "Skylights!" and "Ventilation!" and "Observation!" and having people running off to go rescue or rebuild them. I try to tell my teammates that the way to save Skylights is to take and hold Overlook. If the current BT makes running after RTs less valuable and encourages tactical play to secure territory, then I'm all for it. thats not clear yet. i keep the RT scaled down to 8 t.res for ~2 more days and see what its does to the game play.
matso
Master of Patches
May 22
Do the "Performance-Jam"!!!
SteveRock wrote: » CrazyEddie wrote: » Steve, Cory - as long as you're answering performance and technology questions: Are you doing any work around splitting up the game logic code so that it could be handled in multiple lua threads? I know that's not easy (and I know that's an understatement) but it seems like the payoff could be huge. We do this for prediction already, which resulted in huge gains, but that's literally running two separate Lua worlds. Doing it within the same world is more complex, and much more risky (in terms of bugs, code maintainability, whether or not it would even work, etc. etc.). So, it's less likely we'll pursue this avenue. The extra Lua VM running the Predict world is very much a special case; it it responsible for taking the server network updates and merge it with any missing client moves, then deliver that to the main thread. It reduced an O(fps^2) problem in the main thread to an O(network rate) in a secondary thread - a very good thing. Also increased fps so much that Max had to add move rate limiters to avoid servers imploding under the load ... oh, fun times, good times (http://forums.unknownworlds.com/discussion/122189/224-tech-changes-part-1 for those interested in more details ) Lua does not support true multithreading (yet), so if you want to split the logic work you would probably go for using multiple Lua VMs running in their own threads, and then have a merge phase in between... doable, but adding lots of complexity. So going for LuaJIT first is the right way ... hopefully, it will be fast enough to tide Spark over until Lua supports true multithreading.
SteveRock
May 22
Do the "Performance-Jam"!!!
CrazyEddie wrote: » Steve, Cory - as long as you're answering performance and technology questions: Are you doing any work around splitting up the game logic code so that it could be handled in multiple lua threads? I know that's not easy (and I know that's an understatement) but it seems like the payoff could be huge. We do this for prediction already, which resulted in huge gains, but that's literally running two separate Lua worlds. Doing it within the same world is more complex, and much more risky (in terms of bugs, code maintainability, whether or not it would even work, etc. etc.). So, it's less likely we'll pursue this avenue.
matso
Master of Patches
May 22
Do the "Performance-Jam"!!!
CrazyEddie wrote: » Steve, Cory - as long as you're answering performance and technology questions: Are you doing any work around splitting up the game logic code so that it could be handled in multiple lua threads? I know that's not easy (and I know that's an understatement) but it seems like the payoff could be huge. Right now the client uses slightly more than 2 cores at peak load, so further MT would not benefit 2-core machines much. Better to go for LuaJIT, which uses the CPU more efficiently.
MurphyIdiot
NS2 programmer
May 22
time to make the mods - problem
Your problem is in the game_setup.xml file. If you open the console with ~ in game, you will see this being spammed: Error: Error reading end tag. Error: Couldn't load 'game_setup.xml' It failed to parse the file due to this line having a typo: <predeict>lua/ModPredict.lua</predict> The console and log file are your friend
SteveRock
May 22
Do the "Performance-Jam"!!!
moultano wrote: » SteveRock wrote: » And since you seem to be fairly technically minded, the major challenge we face with LuaJIT is the Lua->C++ API. For LuaJIT to be performant, you have to architect that API in some pretty specific ways, otherwise you will always break the JIT compiles and get almost no benefit from it. Completely changing the API is not an attractive option (rewrite a lot of code..break all the mods..), so we're currently investigating ways of avoiding this. Tell us more! Reading about things like this gives me a "break out the profiler" itch. It's exciting. Is there a performance sensitive subset you could rewrite, and assume the remainder will fall back to being interpreted? One challenge is even identifying the hotspots, so Dushan has been working on a sample-based Lua profiler to help with this. Think of it as Intel VTune for Lua scripts (cuz otherwise, VTune just tells us...Lua is slow). Once that is done, we can better assess if it's possible to address just that subset.
Forums
Recent Threads
Activity
Best of...
Unknown Worlds Entertainment
Getting Started
Framedrops when using mouse in lategame
91
views
5
comments
0
points
Most recent by
joshhh
4:49PM
Technical Support
Your game files do not match the servers....
351
views
23
comments
0
points
Most recent by
BlueEyedDragon
2:54PM
Technical Support
config_path issues
71
views
14
comments
0
points
Most recent by
Scrajm
12:50PM
Server Discussion
Crash on launch
21
views
3
comments
0
points
Most recent by
noxn
6:39AM
Technical Support
[bug] Couldn't drop skylights' RT
51
views
2
comments
0
points
Most recent by
IronHorse
3:53AM
Technical Support
More Discussions
General
Do the "Performance-Jam"!!!
4.3K
views
157
comments
16
points
Most recent by
StrikerX3
6:42PM
General Discussion
Sewlek's Balance mod
49.7K
views
1.8K
comments
1
point
Most recent by
ritualsacrifice
6:40PM
General Discussion
Constructive Comments for Voting Menu
11
views
0
comments
0
points
Started by
lordfarva
6:24PM
Ideas and Suggestions
Please lower shotgun power
2.4K
views
141
comments
1
point
Most recent by
Ghosthree3
6:08PM
General Discussion
Cool features/tactics rarely used.
2.2K
views
75
comments
6
points
Most recent by
Locklear
5:53PM
General Discussion
More Discussions
Veteran
Custom HUD mod
451
views
11
comments
0
points
Most recent by
Locklear
10:44AM
Competitive Play
ESL
Opening tournament
Webbed
2.8K
views
49
comments
0
points
Most recent by
fanatic
May 22
Competitive Play
Australian Cyber Gamer Tournament Season 1 comes to a close
231
views
8
comments
0
points
Most recent by
sebastianoswell
May 22
Competitive Play
Quoth Gaming recruiting for ENSL
151
views
2
comments
0
points
Most recent by
SammyG
May 21
Competitive Play
Pro players - Competitive play Vs Pub Play
1.4K
views
39
comments
0
points
Most recent by
joshhh
May 21
Competitive Play
More Discussions
Creation
New launchpad
71
views
5
comments
0
points
Most recent by
oldassgamers
5:48PM
Mapping
ExtraEntitiesMod
6.7K
views
226
comments
0
points
Most recent by
JimWest
5:14PM
Modding
ns2_co_angst
171
views
10
comments
1
point
Most recent by
DarkSeraph
4:46PM
Mapping
Xenoswarm - a new mod from the NS2Combat team!
1.6K
views
39
comments
9
points
Most recent by
peregrinus
4:28PM
Modding
help with spark editor
51
views
3
comments
0
points
Most recent by
DarkSeraph
3:42PM
Mapping
More Discussions
Other
Xbox One (1)
451
views
31
comments
0
points
Most recent by
ScardyBob
6:39PM
Off-Topic
GTX 780
111
views
11
comments
0
points
Most recent by
BlueEyedDragon
5:27PM
Off-Topic
Lowering ping tips? anyone?
Anyone have any?
1.3K
views
5
comments
0
points
Most recent by
kabali
1:07PM
NS General Discussion
Post YouTube videos plx. Second Encounter.
That is still all.
607.1K
views
3.7K
comments
0
points
Most recent by
Konohas Perverted Hermit
4:29AM
Off-Topic
Do all dating websites suck?
151
views
4
comments
0
points
Most recent by
ellnic
12:20AM
Off-Topic
More Discussions
Community
Copyright
Developer
Terms of Use
Privacy
Unknown Worlds Entertainment Logo
© 2013,
Unknown Worlds Entertainment
. All rights reserved.
Visual Design by
Fully Illustrated