Luanti logo

IRC log for #minetest-dev, 2021-10-24

| Channels | #minetest-dev index | Today | | Google Search | Plaintext

All times shown according to UTC.

Enable nick filtering
Time Nick Message
17 more elements. Show/hide.
10:11 MTDiscord <luatic> sfan5: Have you considered the performance implications of https://github.com/minetest/irrlicht/commit/81bae5b717a79fc2b05a09f760afc7b44da98487 ? It looks like those "questionable" bit hacks were used to improve performance by getting rid of expensive branching.
10:13 MTDiscord <Sublayer plank> improving performance by making it return wrong at times doesn't feel like a smart way of doing things
10:15 sfan5 yes and the result I arrived at is "the compiler should optimize it somehow"
10:16 sfan5 perhaps using a CMOV instructions or by applying a (this time correct) version of the bit hacks itself
11:02 MTDiscord <luatic> Well, IIRC ternaries don't use branching, and simple if-return things might be optimized to ternaries.
11:16 calcul0n__ joined #minetest-dev
11:32 pgimeno compilers know how to optimize return a < b ? a : b; and similar
11:32 pgimeno if the boolean operation is better, they will use that
2 more elements. Show/hide.
13:30 pgimeno this proves that the compiler knows about it: https://godbolt.org/z/vo4Ma676x
13:31 pgimeno in x86-64, ARM etc. it uses conditional move (cmov / movlt)
23 more elements. Show/hide.

| Channels | #minetest-dev index | Today | | Google Search | Plaintext