User talk:Hvengel: Difference between revisions

Jump to navigation Jump to search
Line 26: Line 26:


: Emilian: while I agree that the Extra-500 is really slow for me as well, how well it performs is not relevant to this discussion. The Nasal used there is more comparable to "500+600+700+... lines of Nasal code adding up" than "5+5+5+... lines of Nasal code adding up" – because 5 lines of Nasal code takes up no time at all (unless it calls expensive functions and/or uses recursion and/or loops, which the Extra-500 certainly uses some of). The Extra-500 is really complex (as far as I understand it) and is subject to different issues, issues which don't affect small scripts (i.e. 5-liners). Some of the lack of efficiency is not even Nasal code, it's hard coded (e.g. the props.Node interface, which doesn't use cppbind and thus can create unnecessary temporary GC-able objects if used incorrectly). Some of it is the lack of efficiency in the Extra-500's code versus what being accomplished – i.e. it could be much simpler in places (and actually use MapStructure). Some of it is the positioned queries – those are not microscopic yet, but probably will be soon. Et cetera. There's different ways we could prove it's inefficient code. Nasal itself, however, is very efficient from what I've seen and simple animations are not time-wasters at all. Even 100 lines of simple Nasal animations should execute in under ~2-4ms, I would guess, on reasonably modern hardware if it doesn't use certain constructs (e.g. props.globals.getNode("").setValue/getValue, where the node isn't cached, see [http://forum.flightgear.org/viewtopic.php?f=30&t=22155#p201370], or other GC nightmares). Even GC'ing is extremely fast on my computer :-). [[User:Philosopher|—Philosopher]] ([[User talk:Philosopher|talk]]) 13:55, 14 July 2014 (UTC)
: Emilian: while I agree that the Extra-500 is really slow for me as well, how well it performs is not relevant to this discussion. The Nasal used there is more comparable to "500+600+700+... lines of Nasal code adding up" than "5+5+5+... lines of Nasal code adding up" – because 5 lines of Nasal code takes up no time at all (unless it calls expensive functions and/or uses recursion and/or loops, which the Extra-500 certainly uses some of). The Extra-500 is really complex (as far as I understand it) and is subject to different issues, issues which don't affect small scripts (i.e. 5-liners). Some of the lack of efficiency is not even Nasal code, it's hard coded (e.g. the props.Node interface, which doesn't use cppbind and thus can create unnecessary temporary GC-able objects if used incorrectly). Some of it is the lack of efficiency in the Extra-500's code versus what being accomplished – i.e. it could be much simpler in places (and actually use MapStructure). Some of it is the positioned queries – those are not microscopic yet, but probably will be soon. Et cetera. There's different ways we could prove it's inefficient code. Nasal itself, however, is very efficient from what I've seen and simple animations are not time-wasters at all. Even 100 lines of simple Nasal animations should execute in under ~2-4ms, I would guess, on reasonably modern hardware if it doesn't use certain constructs (e.g. props.globals.getNode("").setValue/getValue, where the node isn't cached, see [http://forum.flightgear.org/viewtopic.php?f=30&t=22155#p201370], or other GC nightmares). Even GC'ing is extremely fast on my computer :-). [[User:Philosopher|—Philosopher]] ([[User talk:Philosopher|talk]]) 13:55, 14 July 2014 (UTC)
:: Thanks, but no thanks. And btw, you might want to not get things so literally (the "5 lines of nasal" was exactly a reference to this kind of 'evangelism' going on these days with nasal, where to no matter what problem the solution is suggested as "easily done in x lines of nasal"). I'm sorry but I'm not going to drink your cool-aid, and if there's an alternative solution that circumvents nasal I'm going to suggest it, even if it's going to be harder/more complicated to implement, I'm convinced it will be better performance wise.
:: I think some apologies towards Hvengel are in order, for abusing his talk page.
::[[User:I4dnf|I4dnf]] ([[User talk:I4dnf|talk]]) 14:34, 14 July 2014 (UTC)


== Ubershader Issues ==
== Ubershader Issues ==
422

edits

Navigation menu