SPO PROJECT - STAGE 2




Hi everyone, for this blog I will talk about the second stage of the project, how it went and what I did. I've noticed that this class looks very difficult but when you do the actual work its extremely easy. For this Stage I had to do some profiling on the open source project i selected in Stage 1. The link to stage 1 can be found at the bottom of this post. Like the first stage i had to do this for the AArch64 and the x86_64 architectures.
The first architecture i attempted this on was a x86_64 architecture and I was a bit confused. During stage 1 and 83mb file took around 4 minutes on average to compress. After trying again today it was taking over 8 minutes. I could not figure out why this was happening and I spent quite some time on it. Defeated, I decided to just use a 43mb file instead that ended up taking the amount of time I posted on stage 1.

  X86_65

So after watching the helpful video that my professor posted on the CDOT wiki, I attempted to "profile". The first thing I had to do was configure the CFLAGS. In the YouTube video my professor did this in the command line but what i was open the make file command and manually change the CFLAGS in the file. This is what the start of the Makefile looked like after I finished. Inside the Blue circles are what I added to the CFLAGS.








After doing this I basically just ran the project like normal to see what the times where. They were roughly the same as they were on stage 1 but this time the file was half the size.


The next was the actual profiling. After setting the CFLAGS and running it I had gotten a new file in the project directory call gmon.out. The next command I had to write printed what functions took the longest on the screen. The command I wrote was gprof ./zopfli file.txt. As you can see in the photo posted below the function that took the longest time was ZopfliUpdateHash which took the longest amount of time which can be seen on the left. If i were to attempt to optimize this code, optimizing the ZopfliUpdateHash function would be the top choice. This was for an x86_64 system. Below i will post my timings for the AArch64 system.


AArch86 


So for the AArch86 systems it was a bit weird. I wasn't able to log to log into the aarchie server but I managed to sign into the Israel server. So this time I did the exact same stuff as above. The times on the Israel server was a lot longer compared to the x86_64, more than double.



The profiling times  were pretty much the exact same with ZopfliUpdateHash taking the longest time out of all the functions. Though the numbers did vary, on average ZopfliUpdateHash did take less time but the other functions took alot longer.


            






















Comments

Popular posts from this blog

Lab 4

Lab 3 - Continued