I’m using MFC in Visual Studios. I wondered what the best way to measure the speed/efficiency of an operation (eg Function A vs Function B) working in this specific IDE. Can this be done with breakpoints?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
No, use
QueryPerformanceCounter(docs) for accurate measurements of speed. From comments from @MadKeithV, this seems to not be a good solution, as CPU speed scaling (reducing CPU speed according to current load) may change CPU tick length.Using a good profiler is a better idea, or just use
clock_tto measure.