in Education by
Suppose you have a fairly large (~2.2 MLOC), fairly old (started more than 10 years ago) Windows desktop application in C/C++. About 10% of modules are external and don't have sources, only debug symbols. How would you go about reducing application's memory footprint in half? At least, what would you do to find out where memory is consumed? JavaScript questions and answers, JavaScript questions pdf, JavaScript question bank, JavaScript questions and answers pdf, mcq on JavaScript pdf, JavaScript questions and solutions, JavaScript mcq Test , Interview JavaScript questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)

1 Answer

0 votes
by
Override malloc()/free() and new()/delete() with wrappers that keep track of how big the allocations are and (by recording the callstack and later resolving it against the symbol table) where they are made from. On shutdown, have your wrapper display any memory still allocated. This should enable you both to work out where the largest allocations are and to catch any leaks.

Related questions

0 votes
    Suppose you have a fairly large (~2.2 MLOC), fairly old (started more than 10 years ago) Windows ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 21, 2022 in Education by JackTerrance
0 votes
    Suppose you have a fairly large (~2.2 MLOC), fairly old (started more than 10 years ago) Windows ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 17, 2022 in Education by JackTerrance
0 votes
    I am working on a very large scale computing library that is using STL heavily. The library is being ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 12, 2022 in Education by JackTerrance
0 votes
    Which package can be integrated with dplyr for large fast tables? (a) Table (b) Data, dplyr (c) Data. ... Debugging of R Programming Select the correct answer from above options...
asked Feb 15, 2022 in Education by JackTerrance
0 votes
    I would like to use CHOLMOD's GPU acceleration, and have found several simple examples on how to use ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Apr 16, 2022 in Education by JackTerrance
0 votes
    I had a program working good (without prompting errors) using references, but I decided to use a pointer-to-pointer array ... that it is there because I have put two flags (cout...
asked Apr 6, 2022 in Education by JackTerrance
0 votes
    Yacc does not permit objects to be passed around. Because the %union can only contain POD types, complex ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 24, 2022 in Education by JackTerrance
0 votes
    I am inputting a 200mb file in my application and due to a very strange reason the memory usage of ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 5, 2022 in Education by JackTerrance
0 votes
    I am inputting a 200mb file in my application and due to a very strange reason the memory usage of ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 5, 2022 in Education by JackTerrance
0 votes
    What is the memory limit in R for 64 bit system? (a) 8 TB (b) 9TB (c) 10TB (d) 16TB The ... Functions and Debugging of R Programming Select the correct answer from above options...
asked Feb 15, 2022 in Education by JackTerrance
0 votes
    What is the memory limit in R for 32 bit system? (a) 8 TB (b) 9TB (c) 10TB (d) 3GB The ... Functions and Debugging of R Programming Select the correct answer from above options...
asked Feb 13, 2022 in Education by JackTerrance
0 votes
    I have created a client-server program with Perl using IO::Socket::INET. I access server through CGI ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 4, 2022 in Education by JackTerrance
0 votes
    computer has very large…….? a. memory b.speed c. both a & b d.none of the above Select the correct answer from above options...
asked Dec 15, 2021 in Education by JackTerrance
0 votes
    Which of the following is not a footprint-scanning tool? (a) SuperScan (b) TcpView (c) Maltego (d) OWASP ... Cyber Security questions and answers pdf, mcq on Cyber Security pdf,...
asked Nov 5, 2021 in Education by JackTerrance
0 votes
    What are the effects of reducing the voting age from 21 years to 18 years? Please answer the above question....
asked Aug 14, 2022 in Education by JackTerrance
...