Question: Compile and run the program without any extra optimizations, but with profiling for timing: gcc - c - pg - O 0 main.c gcc -

Compile and run the program without any extra optimizations, but with profiling for timing:
gcc -c -pg -O0 main.c
gcc -c -pg -O0 tree.c
gcc -c -pg -O0 list.c
gcc main.o tree.o list.o -pg -O0-o assign1-0
Run the program twice timing it both times, and answer the following:
How for 500,000 numbers how many self seconds did generateList() take?
How for 500,000 numbers how many self seconds did generateTree() take?

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!