added trace()