>>106484576
i dont understand what your pic is supposed to mean. it doesn't show a chain of operations like i(h(g(f(a)))), much less the intermediary values, like f(a), g(f(a)), etc.
>>106484592
do you realize that this is literally what your compiler is converting your code to in the background and that's it's not slow or wasteful at all actually? do you know what SSA form is?