jwmhjwmh wrote: ↑Wed May 18, 2022 01:38This mod just lets you use LuaJIT's builtin profiler. You need to add it to the secure.trusted_mods list. This profiler is good for pinpointing expensive parts of the code.
How to Use
(Optional) dependencies: none
- Enable the mod.
- In-game start the profiler with /jitprofiler_start 1 <filename>. The profiling data will be written to <worldpath>/jitprofiles/<filename>.
- Collect data for a while.
- Stop profiling with /jitprofiler_stop or by exiting the world.
- Download FlameGraph.
- Create a flamegraph SVG with ./flamegraph.pl <worldpath>/jitprofiles/<filename> > graph.svg.
- Open the SVG in your browser.
- The top level of each stack snapshot will be "C", "G", "I", "J", or "N", representing C code, garbage collection, interpreter, JIT compilation, or compiled code, respectively.
LuaJIT Profile - on engine, buildit and mods ?
- Festus1965
- Member
- Posts: 4181
- Joined: Sun Jan 03, 2016 11:58
- GitHub: Festus1965
- In-game: Festus1965 Thomas Thailand Explorer
- Location: Thailand ChiangMai
- Contact:
LuaJIT Profile - on engine, buildit and mods ?
based on new offered [Mod] LuaJIT Profiler [jitprofiler] the discussion should not be in the Thread about the mod itself ...
Human has no future (climate change)
If urgend, you find me in Roblox (as CNXThomas)
If urgend, you find me in Roblox (as CNXThomas)
- Festus1965
- Member
- Posts: 4181
- Joined: Sun Jan 03, 2016 11:58
- GitHub: Festus1965
- In-game: Festus1965 Thomas Thailand Explorer
- Location: Thailand ChiangMai
- Contact:
LuaJIT Profile - on engine, buildit and mods ?
How to 'read'/use it ?
example:
run about 10 minutes, starting one login to start /jitprofiler end exit, finish log with close terminal
engine 5.5.1 - game 'empty'
* without profiler
** empty.txt.zip
** empty.svg
* with profiler
** empty-profiler.txt.zip
** empty-profiler.svg
with minetest_game
* without profiler
** minetest.txt.zip
** minetest.svg
* with profiler
** minetest-profiler.txt.zip
** minetest-profiler.svg
with MTG + pipeworks
* without profiler
** pipeworks.txt.zip
** pipeworks.svg
* with profiler
** pipeworks-profiler.txt.zip
** pipeworks-profiler.svg
MTG with TOP 20 mods AsiaThailand but also on empty world, no any node or item of this mods existing
running,
last to add
* without profiler
** zip
** svg
... then I will see what I can read out of it ...
I read them from down to up ... and see that the 3rd level still C, but get less (in % sure) but still big part at that stage, but I not sure yet if it changes, or still do the same in absolute but less in % work as before = stable same routine, whatever mod gets in plus.
And I see line 4 up ONLY the left part gets new information ...
OK, can click the tiny ones to zoom in ...
example:
run about 10 minutes, starting one login to start /jitprofiler end exit, finish log with close terminal
engine 5.5.1 - game 'empty'
* without profiler
** empty.txt.zip
** empty.svg
* with profiler
** empty-profiler.txt.zip
** empty-profiler.svg
with minetest_game
* without profiler
** minetest.txt.zip
** minetest.svg
* with profiler
** minetest-profiler.txt.zip
** minetest-profiler.svg
with MTG + pipeworks
* without profiler
** pipeworks.txt.zip
** pipeworks.svg
* with profiler
** pipeworks-profiler.txt.zip
** pipeworks-profiler.svg
MTG with TOP 20 mods AsiaThailand but also on empty world, no any node or item of this mods existing
running,
last to add
* without profiler
** zip
** svg
... then I will see what I can read out of it ...
I read them from down to up ... and see that the 3rd level still C, but get less (in % sure) but still big part at that stage, but I not sure yet if it changes, or still do the same in absolute but less in % work as before = stable same routine, whatever mod gets in plus.
And I see line 4 up ONLY the left part gets new information ...
OK, can click the tiny ones to zoom in ...
Human has no future (climate change)
If urgend, you find me in Roblox (as CNXThomas)
If urgend, you find me in Roblox (as CNXThomas)
- jwmhjwmh
- Developer
- Posts: 125
- Joined: Sun Jul 18, 2021 14:10
- GitHub: TurkeyMcMac
Re: LuaJIT Profile - on engine, buildit and mods ?
By the way, I have found that the "C" part is smaller on a dedicated server (that is, a server using dedicated_server_step.)
- Festus1965
- Member
- Posts: 4181
- Joined: Sun Jan 03, 2016 11:58
- GitHub: Festus1965
- In-game: Festus1965 Thomas Thailand Explorer
- Location: Thailand ChiangMai
- Contact:
Re: LuaJIT Profile - on engine, buildit and mods ?
What you mean with 'dedicated server', a setting ?
Human has no future (climate change)
If urgend, you find me in Roblox (as CNXThomas)
If urgend, you find me in Roblox (as CNXThomas)
- jwmhjwmh
- Developer
- Posts: 125
- Joined: Sun Jul 18, 2021 14:10
- GitHub: TurkeyMcMac
Re: LuaJIT Profile - on engine, buildit and mods ?
I mean when you start up Minetest with the --server option.
- Festus1965
- Member
- Posts: 4181
- Joined: Sun Jan 03, 2016 11:58
- GitHub: Festus1965
- In-game: Festus1965 Thomas Thailand Explorer
- Location: Thailand ChiangMai
- Contact:
Re: LuaJIT Profile - on engine, buildit and mods ?
sorry,jwmhjwmh wrote: ↑Thu May 19, 2022 02:00I mean when you start up Minetest with the --server option.
but I use 'minetestserver' most, self compiled and
'dedicated_server_step' is a standard setting by default
Code: Select all
# Length of a server tick and the interval at which objects are generally updated over
# network.
# type: float
# dedicated_server_step = 0.09
to https://github.com/minetest/minetest/bl ... mple#L1602
so it is there always, easiest so check with logged in gamer priv server
Code: Select all
/set dedicated_server_step
on started 'minetestserver' no settings in minetest.conf I get 'dedicated_server_step = 0.09'
on started 'minetest --server' no settings in minetest.conf I get 'dedicated_server_step = 0.09' = same !
so your post does not make any sense.
Human has no future (climate change)
If urgend, you find me in Roblox (as CNXThomas)
If urgend, you find me in Roblox (as CNXThomas)
- jwmhjwmh
- Developer
- Posts: 125
- Joined: Sun Jul 18, 2021 14:10
- GitHub: TurkeyMcMac
Re: LuaJIT Profile - on engine, buildit and mods ?
I'm pretty sure minetestserver is equivalent to minetest --server. When one starts a singleplayer world, on the other hand, it seems that dedicated_server_step is ignored.Festus1965 wrote: ↑Thu May 19, 2022 02:18sorry,
but I use 'minetestserver' most, self compiled and
'dedicated_server_step' is a standard setting by defaultvia https://wiki.minetest.net/Minetest.confCode: Select all
# Length of a server tick and the interval at which objects are generally updated over # network. # type: float # dedicated_server_step = 0.09
to https://github.com/minetest/minetest/bl ... mple#L1602
so it is there always, easiest so check with logged in gamer priv serverCode: Select all
/set dedicated_server_step
on started 'minetestserver' no settings in minetest.conf I get 'dedicated_server_step = 0.09'
on started 'minetest --server' no settings in minetest.conf I get 'dedicated_server_step = 0.09' = same !
so your post does not make any sense.
- Festus1965
- Member
- Posts: 4181
- Joined: Sun Jan 03, 2016 11:58
- GitHub: Festus1965
- In-game: Festus1965 Thomas Thailand Explorer
- Location: Thailand ChiangMai
- Contact:
Re: LuaJIT Profile - on engine, buildit and mods ?
I started a singeplayer session, /grantme all, then '/set dedicated_server_step' as I am sure no settings done
and got also 'dedicated_server_step = 0.09' as the default is.
So answer is no,
and answer is this settings is always there as a default !
Human has no future (climate change)
If urgend, you find me in Roblox (as CNXThomas)
If urgend, you find me in Roblox (as CNXThomas)
- jwmhjwmh
- Developer
- Posts: 125
- Joined: Sun Jul 18, 2021 14:10
- GitHub: TurkeyMcMac
Re: LuaJIT Profile - on engine, buildit and mods ?
The setting is still present in singleplayer, but it is just ignored AFAICT.Festus1965 wrote: ↑Thu May 19, 2022 03:02I started a singeplayer session, /grantme all, then '/set dedicated_server_step' as I am sure no settings done
and got also 'dedicated_server_step = 0.09' as the default is.
- Festus1965
- Member
- Posts: 4181
- Joined: Sun Jan 03, 2016 11:58
- GitHub: Festus1965
- In-game: Festus1965 Thomas Thailand Explorer
- Location: Thailand ChiangMai
- Contact:
Re: LuaJIT Profile - on engine, buildit and mods ?
Yes, sure, as there is no network connected other gamer, sure that this is not needed or used,
but YOUR intention was to tell it is not even set !
But so far interesting, to make same tests on SinglePlayer, as to imagine or detect, what parts of work are server (network) depending that we might not expect.
Human has no future (climate change)
If urgend, you find me in Roblox (as CNXThomas)
If urgend, you find me in Roblox (as CNXThomas)
- jwmhjwmh
- Developer
- Posts: 125
- Joined: Sun Jul 18, 2021 14:10
- GitHub: TurkeyMcMac
Re: LuaJIT Profile - on engine, buildit and mods ?
That was not my intention. But it doesn't really matter anyway.Festus1965 wrote: ↑Thu May 19, 2022 03:10Yes, sure, as there is no network connected other gamer, sure that this is not needed or used,
but YOUR intention was to tell it is not even set !
But so far interesting, to make same tests on SinglePlayer, as to imagine or detect, what parts of work are server (network) depending that we might not expect.
- Festus1965
- Member
- Posts: 4181
- Joined: Sun Jan 03, 2016 11:58
- GitHub: Festus1965
- In-game: Festus1965 Thomas Thailand Explorer
- Location: Thailand ChiangMai
- Contact:
Re: LuaJIT Profile - on engine, buildit and mods ?
yes, as a single-player will not complain about lag ?
mhh, but anyway
I will use it so see the difference from
* high impact mods (pipeworks+technic / petz / ...)
to their counterpart with
* low impact mods (techage / mobs_redo / ...)
as from the other thread, maybe understand also why and how ...
but for me it is easier: I just choose the lower impact version, I don't write code anymore much
my time is gone ... selling first basic program "inventor on C64" in 1981/83 to neighbor bakery and help to do it also. That was so fast against old manual writing down all things. Best of computer class at that 2 years.
Human has no future (climate change)
If urgend, you find me in Roblox (as CNXThomas)
If urgend, you find me in Roblox (as CNXThomas)
Who is online
Users browsing this forum: No registered users and 23 guests