Trace function is added.