Add code gen for stream arguments, integrate and test addr.cpp