Add stack based intermediate value management.
Not compilable now!!