SPO600: LAB6 (Algorithm Selection Lab)

To optimize volume, three options were performed for this lab. All of them used 0.75 for the volume factor, and 500 million random data were used. Command time and /usr/bin/time was used to check its details, but loss time was found between the total time and the sum of the user and system time.

1. Volume_out = sample data * volume_factor : This method was simple but slow due to float multiplication and two types of conversions occurred.

lab6-1Irene.PNG

2. using lookup table: In this option, multiplication happened while creating the lookup table so that it was faster than the previous option.

lab6-2Irene.PNG

3. using fixed-point: the volume factor was converted to fixed point integer as a setup, and then multiplied by a binary as the actual calculation. As you see below, this method was much faster than the previous versions.

lab6-3Irene.PNG

Last, option O3 for the compile was used to compare the time after optimization, resulted in shorter time.

lab6Irene_O3.PNG

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s