Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add log of cost time #1390

Merged
merged 2 commits into from
Sep 17, 2021
Merged

Conversation

ShiningZhang
Copy link
Collaborator

@ShiningZhang ShiningZhang commented Sep 17, 2021

  1. 添加server耗时log,修改pdcodegen.cpp,在生成service::inference函数时添加耗时log
  2. 当req->profile_server()==false时,只会打印logid及总耗时;为true时,会增加各个op耗时。
  3. 格式如下:[serving]logid=0,op0=0.123ms,op1=1.123ms,op2=0.123ms,cost=2.123ms.
  4. 添加client耗时log,通过FLAGS_profile_client可以打开client各阶段耗时,通过FLAGS_profile_server可以打开server端op耗时
  5. 格式如下:
    [client]logid=0,client_pre_cost=0.709ms,client_infer_cost=4.177ms,client_post_cost=0.116ms,client_cost=5.003ms,op0=0.083ms,op1=0.364ms,op2=0.093ms,server_cost=1.235ms.

@paddle-bot-old
Copy link

Thanks for your contribution!

@TeslaZhao TeslaZhao merged commit eb16b33 into PaddlePaddle:develop Sep 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants