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

Refine CUDA profiler and delete the test file. #6715

Merged
merged 4 commits into from
Dec 25, 2017

Conversation

qingqing01
Copy link
Contributor

Fix #6714
Fix #6033

  • Now the config file is created in C++ code, move it to Python code.
  • Delete the file in Python generated in the unit testing.

"enableonstart 0",
"conckerneltrace",
"active_warps",
"active_warps",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why "active_warps" appeared two times, and "cacheconfigrequested" appeared three times?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix, Thanks!

config_file = 'nvprof_config_file'
with open(config_file, 'wb') as fp:
fp.writelines(["%s\n" % item for item in config])
core.nvprof_init(output_file, output_mode, config_file)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we check whether output_file exists? If output_file has already existed, does this profile result to rewrite the original content of the output_file?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I do not change the code, all you mentioned can be done by the users when using this interface. Thanks!

@chengduoZH
Copy link
Contributor

Too much options will affect the speed of the program.

@qingqing01
Copy link
Contributor Author

@chengduoZH Thanks for your careful review. I resume the config after a verification.

Copy link
Contributor

@chengduoZH chengduoZH left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM+

@qingqing01 qingqing01 merged commit 87aae57 into PaddlePaddle:develop Dec 25, 2017
@qingqing01 qingqing01 deleted the cuda_profile branch November 14, 2019 05:26
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.

None yet

2 participants