Probably to construct the return value from t. Try turning on more optimizations and see if it makes a difference. When I run your program the only output that I see is "move assignment val:50".
Yes that's what is happening i guess; I think the compiler is converting the return value to T like this: t2 = T{ g() }
I just compiled this program in cpp.sh and it gave me the same result as you.
turning on optimizations did not make any differences; I am using visual studio 2017