profiler

Benchmarking, Profiling on Virtual Machines

妖精的绣舞 提交于 2019-12-24 11:01:05
问题 On many different sources you can read about time keeping issues in virtual machines. As every benchmark relies on time keeping i am not sure how to interpret e.g. apache benchmark or xdebug profiler results on vmware and how credible they are. http://communities.vmware.com/docs/DOC-5581 VMware suggests to build a special vm for performance testing. There are many tips in addition which seems to be workaround solutions (install VMware Tools, special configuration and so on). Especially when

Is there an equivalent tool like sql profiler for mongodb?

让人想犯罪 __ 提交于 2019-12-24 10:46:17
问题 I would like to know if there is an equivelent tool like sql profiler for mongodb. Specifically, I would like to see what monogdb queries are being generated and are being run from my code. So, when I have code such as: var Logs = MvcApplication.MongoLoggingDatabase.GetCollection<Log>("Log") .Find(queryDocument) .Select(x => new LogDto { ModelNumber = x.Request.ModelNumber, Make = x.Request.Make, TimeStamp = x.TimeStamp, UserId = x.UserId }) .OrderByDescending(x => x.TimeStamp) .Skip(pageSize

nvprof events “fb_subp0_read_sectors” and “fb_subp1_read_sectors” do not report correct results

杀马特。学长 韩版系。学妹 提交于 2019-12-24 08:49:07
问题 I tried to count the number of DRAM (global memory) accesses for simple vector add kernel. __global__ void AddVectors(const float* A, const float* B, float* C, int N) { int blockStartIndex = blockIdx.x * blockDim.x * N; int threadStartIndex = blockStartIndex + threadIdx.x; int threadEndIndex = threadStartIndex + ( N * blockDim.x ); int i; for( i=threadStartIndex; i<threadEndIndex; i+=blockDim.x ){ C[i] = A[i] + B[i]; } } Grid Size = 180 Block size = 128 size of array = 180 * 128 * N floats

Profile a C shared library called by Ruby program

柔情痞子 提交于 2019-12-23 22:47:01
问题 I have a program written in Ruby and C. The C portion is a shared library, which is an extension for the Ruby program. I want to profile the C shared library I wrote, using gprof. I compile the shared library like this: gcc -I. -I/usr/lib/ruby/1.8/i486-linux -I/usr/lib/ruby/1.8/i486-linux -I. -D_FILE_OFFSET_BITS=64 -fPIC -fno-strict-aliasing -g -march=i686 -O2 -ggdb -pg -fPIC -c extension.c gcc -shared -o extension.so extension.o -L. -L/usr/lib -L. -Wl,-Bsymbolic-functions -rdynamic -Wl,

how can I profile class methods of my python app?

落爺英雄遲暮 提交于 2019-12-23 21:31:46
问题 In the past I've written python code with all functions in the same file, and I could profile my programs using the following code: This is a decorator I wrote: def do_profile(cond): def resdec(f): if not cond: return f return profile(f) return resdec And this is how I use it: @do_profile(DO_PROFILE) def my_func(): return 1 I would then invoke kernprof.py on my script: kernprof.py -l my_program.py In the meantime I got more familiar with OOP and I rewrote my program into many classes and the

unable to accumulate time using gprof - the gnu profiler

强颜欢笑 提交于 2019-12-23 12:35:36
问题 I am running cygwin on windows and using latest version of gprof for profiling my code. My problem is that the flat profile shows zero sec for each of the functions in my code, I even tried to loop the functions(tried a for loop for a million) but gprof is unable to accumulate any time .Please help . Here is one of my sample function. bool is_adjacent(const char* a ,const char* b) { for(long long iter=0;iter<=1000000;iter++){ string line1="qwertyuiop"; string line2="asdfghjkl"; string line3=

Xamarin.Forms not freeing (and so leaking) UI elements when a Page is popped

依然范特西╮ 提交于 2019-12-23 05:38:11
问题 We're experiencing memory leaks in our Xamarin.Forms Android application, and I've been investigating using Profiler. This has led me to running Profiler against a very basic Forms app. The very basic Forms app is based on the simple List->Detail template project which is available in Visual Studio For Mac. All it does is navigate from a list page to a details page using the inbuilt navigation stack. async void OnItemSelected(object sender, SelectedItemChangedEventArgs args) { var item = args

What techniques can you use to profile your code

可紊 提交于 2019-12-22 10:32:26
问题 Some of the platforms that I develop on, don't have profiling tools. I am looking for suggestions/techniques that you have personally used to help you identify hotspots, without the use of a profiler. The target language is C++. I am interested in what you have personally used. 回答1: I've found the following quite useful: #ifdef PROFILING # define PROFILE_CALL(x) do{ \ const DWORD t1 = timeGetTime(); \ x; \ const DWORD t2 = timeGetTime(); \ std::cout << "Call to '" << #x << "' took " << (t2 -

What is Hard Faults in XPerf

試著忘記壹切 提交于 2019-12-22 09:36:00
问题 I'm trying to profile a system with XPerf. And see that performance problems occurs when there is activity in HardFaults ! But what I cant figure out and find in google what are these Hard Faults that xperf shows. What are they related to? What do they indicate? Is there any universal remedy for such situations? Hard faults table 回答1: Indeed. "First of all, a "hard fault" was previously called a "page fault" in earlier versions of Windows. Perhaps page faults were more easily understood from

Measuring a program's running time

点点圈 提交于 2019-12-22 09:10:56
问题 I need a tool to measure a program's running time, like gprof. But the resolution of gprof is not good enough (about 0.01 second). oprofile seems can do it, I will try to learn how to get the data about the time info, but I can't. So, who can tell me the steps how to do it, or anyone knows other tool can do the same thing? 回答1: Measuring runtime over a whole program's execution is seldom useful with high resolution; there's too much overhead that you generally don't want to include when you