Open main menu

CDOT Wiki β

Changes

To Thumb or Not to Thumb

19,867 bytes added, 22:37, 15 December 2010
no edit summary
To Thumb? or Not to Thumb?
 
 
== Project Description ==
Description should be no longer than a paragraphFedora-ARM does not use thumb. Include links The purpose of this project is to discover whether thumb provides any relevant significant savings in terms of code size, whether programs compiled to thumb execute more quickly or more slowly than non-thumb programs oncommon ARM processors, whether a thumb compilation takes more or less time than non-line resourcesthumb, and whether there are any other factors that would influence the decision to support thumb. For exampleUltimately, http://google.com or [http://developer.mozilla.org MDC]this project should make a recommendation on the use of the thumb instruction set for the Fedora-ARM secondary architecture.  
== Project Leader(s) ==
I will be working alone for this project.  My name is Tae Hee (Tyler) Leeand I'm taking SBR600 course in 2010 Winter SemesterBlog @ http://tyler-taehee-lee.blogspot.com/search/label/SBR600
thlee3 @ FAS2
thlee3@learn.senecac.on.ca
== Project Contributor(s) ==
Name(s) of people casually working on the project, or who have contributed significant help. Include links to personal pages within wiki
NOTE: only Project Leader(s) should add names here. == What I need to learn ==  - rpmbuild - /usr/lib/rpm/redhat/rpmrc - /usr/lib/rpm/redhat/macros - time - screen - yumdownloader You '''can’t''' add your own name to the Contributor list.- rpm2cpio
== Project Details ==
Provides more depth than the Project Description. This is the place for technical discussions, project specs, or other details. If this gets very long, you might consider breaking this part into multiple pages and linking to them.
== Project Plan ==
Goals for each release:
* 0.1Determine whether THUMB gives advantage in file size compared to NON-THUMB.* 0.2Compare and contrast file sizes between NON-THUMB, THUMB and THUMB2.* 0.3Compare the performance of software compiled with THUMB and NON-THUMB   == Collaboration with classmates == I collaborated with [http://zenit.senecac.on.ca/wiki/index.php/User:Mjeamiguel Mark Eamiguel]. We made arrangements so that I used ''cdot-beagleXM-0-3'' during the day time, and he used during the night to avoid interruption on our benchmarks. There was one night our works on that machine became useless since both of us were compiling at the same time which caused performance drop. We also gave each other tips on working with these remote systems, such as using application ''screen'' and command ''who''.   == Test results == '''Following are the table of file sizes that are produced by ''rpmbuild'' in bytes.''' <br /><div><b>nled-2.52</b></div><div>Produced RPM: '''nled-2.52-6.fc12.armv5tel.rpm'''</div><div>Directories and files: 2 directories, 1 file</div><div>Binary File: '''usr/bin/nled'''</div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''| align="center" | '''THUMB2'''| align="center" | '''THUMB / NON-THUMB'''| align="center" | '''THUMB / THUMB2'''|-| '''RPM'''| align="right" | 20776| align="right" | 20204| align="right" | 20328| align="right" | 0.9724| align="right" | 0.9939|-| '''Directory'''| align="right" | 50892| align="right" | 43084| align="right" | 42684| align="right" | 0.8465| align="right" | 1.0093|-| '''Binary'''| align="right" | 38604| align="right" | 30796| align="right" | 30396| align="right" | 0.7977| align="right" | 1.0131|}<br /><br /><div><b>wget-1.11.4</b></div><div>Produced RPM: '''wget-1.11.4-5.fc12.armv5tel.rpm'''</div><div>Directories and files: 86 directories, 48 files</div><div>Binary File: '''usr/bin/wget'''</div>{| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''| align="center" | '''THUMB2'''| align="center" | '''THUMB / NON-THUMB'''| align="center" | '''THUMB / THUMB2'''|-| '''RPM'''| align="right" | 422360| align="right" | 420788| align="right" | 419852| align="right" | 0.9962| align="right" | 1.0022|-| '''Directory'''| align="right" | 1863679| align="right" | 1811467| align="right" | 1810431| align="right" | 0.9719| align="right" | 1.0006|-| '''Binary'''| align="right" | 226464| align="right" | 174252| align="right" | 173216| align="right" | 0.7694| align="right" | 1.0060|} <br /><br /> <div><b>httpd-2.2.13</b></div><div>Produced RPM: '''httpd-2.2.13-4.fc12.armv5tel.rpm'''</div><div>Directories and files: 37 directories, 334 files</div><div>Binary File: '''usr/sbin/httpd'''</div><div></div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''| align="center" | '''THUMB2'''| align="center" | '''THUMB / NON-THUMB'''| align="center" | '''THUMB / THUMB2'''|-| '''RPM'''| align="right" | 748180| align="right" | 738632| align="right" | 736500| align="right" | 0.9872| align="right" | 1.0029|-| '''Directory'''| align="right" | 2752985| align="right" | 2425373| align="right" | 2408025| align="right" | 0.8810| align="right" | 1.0072|-| '''Binary'''| align="right" | 287988| align="right" | 233660| align="right" | 229712| align="right" | 0.8113| align="right" | 1.0172|} <br /><br /> <div><b>gimp-2.6.7</b></div><div>Produced RPM: '''gimp-2.6.7-2.fc12.armv5tel.rpm'''</div><div>Directories and files: 206 directories, 1204 files</div><div>Binary File 1: '''usr/bin/gimp-2.6'''</div><div>Binary File 2: '''usr/bin/gimp-console-2.6'''</div><div></div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''| align="center" | '''THUMB2'''| align="center" | '''THUMB / NON-THUMB'''| align="center" | '''THUMB / THUMB2'''|-| '''RPM'''| align="right" | 12423104| align="right" | 12431184| align="right" | 12350600| align="right" | 1.0006| align="right" | 1.0065|-| '''Directory'''| align="right" | 45780103| align="right" | 43891439| align="right" | 43730427| align="right" | 0.9587| align="right" | 1.0037|-| '''Binary 1'''| align="right" | 4284848| align="right" | 3450936| align="right" | 3371440| align="right" | 0.8054| align="right" | 1.0236|-| '''Binary 2'''| align="right" | 2131228| align="right" | 1688860| align="right" | 1656092| align="right" | 0.7924| align="right" | 1.0198|} <br /><br /> <div><b>abiword-2.8.1</b></div><div>Produced RPM: '''libabiword-2.8.1-1.fc12.armv5tel.rpm'''</div><div>Directories and files: 39 directories, 617 files</div><div>Binary File: '''usr/lib/libabiword-2.8'''</div><div></div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''| align="center" | '''THUMB2'''| align="center" | '''THUMB / NON-THUMB'''| align="center" | '''THUMB / THUMB2'''|-| '''RPM'''| align="right" | 5561088| align="right" | 4779800| align="right" | 4742828| align="right" | 0.8595| align="right" | 1.0078|-| '''Directory'''| align="right" | 21295155| align="right" | 17055836| align="right" | 16987340| align="right" | 0.8009| align="right" | 1.0040|-| '''Binary'''| align="right" | 5806908| align="right" | 3450936| align="right" | 3371440| align="right" | 0.5943| align="right" | 1.0236|} <br /><br /> <div><b>tar-1.22</b></div><div>Produced RPM: '''tar-1.22-8.fc12.armv5tel.rpm'''</div><div>Directories and files: 79 directories, 49 files</div><div>Binary File: '''bin/tar'''</div><div></div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''| align="center" | '''THUMB2'''| align="center" | '''THUMB / NON-THUMB'''| align="center" | '''THUMB / THUMB2'''|-| '''RPM'''| align="right" | 744340| align="right" | 742784| align="right" | 742180| align="right" | 0.9979| align="right" | 1.0008|-| '''Directory'''| align="right" | 2737195| align="right" | 2681159| align="right" | 2675975| align="right" | 0.9795| align="right" | 1.0019|-| '''Binary'''| align="right" | 251844| align="right" | 195808| align="right" | 190624| align="right" | 0.7775| align="right" | 1.0272|} <br /><br /> <div><b>cpio-2.10</b></div><div>Produced RPM: '''cpio-2.10-5.fc12.armv5tel.rpm'''</div><div>Directories and files: 49 directories, 30 files</div><div>Binary File: '''bin/cpio'''</div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''| align="center" | '''THUMB / NON-THUMB'''|-| '''RPM'''| align="right" | 189908| align="right" | 189276| align="right" | 0.9967|-| '''Directory'''| align="right" | 842194| align="right" | 816194| align="right" | 0.9691|-| '''Binary'''| align="right" | 117064| align="right" | 91064| align="right" | 0.7779|} <br /><br /> <div><b>gzip-1.3.12</b></div><div>Produced RPM: '''gzip-1.3.12-15.fc12.armv5tel.rpm'''</div><div>Directories and files: 9 directories, 33 files</div><div>Binary File: '''bin/gzip'''</div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''| align="center" | '''THUMB / NON-THUMB'''|-| '''RPM'''| align="right" | 116560| align="right" | 115736| align="right" | 0.9929|-| '''Directory'''| align="right" | 263922| align="right" | 252086| align="right" | 0.9551|-| '''Binary'''| align="right" | 61708| align="right" | 49872| align="right" | 0.8082|} <br /><br /> <div><b>bzip2-1.0.5</b></div><div>Produced RPM: '''bzip2-1.0.5-6.fc12.armv5tel.rpm'''</div><div>Directories and files: 7 directories, 21 files</div><div>Binary File: '''/usr/bin/bzip2'''</div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''| align="center" | '''THUMB / NON-THUMB'''|-| '''RPM'''| align="right" | 49476| align="right" | 49232| align="right" | 0.9951|-| '''Directory'''| align="right" | 109233| align="right" | 103449| align="right" | 0.9470|-| '''Binary'''| align="right" | 33024| align="right" | 28076| align="right" | 0.8502|}    '''The following are product of ''time'' command followed by software that are recompiled using ''rpmbuild'' with/without THUMB.'''  <div>System: '''cdot-guru-4-1'''</div><div>File: '''Extracted openoffice.org-3.1.1-19.34.fc12.src.rpm'''</div><div>Command Used: '''time ./tar -cvf nothumb.tar ~/temp'''</div><div></div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''|-| '''1st Attempt'''| align="right" | real 0m33.013s<br />user 0m0.090s<br />sys 0m3.800s| align="right" | real 0m45.746s<br />user 0m0.170s<br />sys 0m3.710s|-| '''2nd Attempt'''| align="right" | real 0m38.410s<br />user 0m0.150s<br />sys 0m3.860s| align="right" | real 0m40.039s<br />user 0m0.130s<br />sys 0m3.760s|-| '''3rd Attempt'''| align="right" | real 0m37.572s<br />user 0m0.110s<br />sys 0m3.820s| align="right" | real 0m42.034s<br />user 0m0.140s<br />sys 0m3.820s|-| '''4th Attempt'''| align="right" | real 0m36.934s<br />user 0m0.150s<br />sys 0m3.670s| align="right" | real 0m43.051s<br />user 0m0.100s<br />sys 0m3.830s|}  <br /><br /><div>System: '''cdot-guru-4-1'''</div><div>File: '''nothumb.tar'''</div><div>Command Used: '''time ~/tar.mthumb-interwork/bin/tar -xvf nothumb.tar'''</div><div></div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''|-| '''1st Attempt'''| align="right" | real 0m48.399s<br />user 0m0.170s<br />sys 0m3.560s| align="right" | real 0m54.197s<br />user 0m0.160s<br />sys 0m3.480s|-| '''2nd Attempt'''| align="right" | real 0m46.306s<br />user 0m0.170s<br />sys 0m3.280s| align="right" | real 0m48.234s<br />user 0m0.160s<br />sys 0m3.680s|-| '''3rd Attempt'''| align="right" | real 0m45.602s<br />user 0m0.130s<br />sys 0m3.800s| align="right" | real 0m49.501s<br />user 0m0.150s<br />sys 0m3.490s|-| '''4th Attempt'''| align="right" | real 0m46.546s<br />user 0m0.110s<br />sys 0m3.420s| align="right" | real 0m52.897s<br />user 0m0.120s<br />sys 0m3.460s|} <br /><br /><div>System: '''cdot-guru-4-1'''</div><div>File: '''gimp.tar (44MB)'''</div><div>Command Used: '''time ./bzip2 ~/gimp.tar'''</div><div></div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''|-| '''1st Attempt'''| align="right" | real 1m4.616s<br />user 0m59.250s<br />sys 0m0.650s| align="right" | real 1m1.379s<br />user 0m57.240s<br />sys 0m0.720s|-| '''2nd Attempt'''| align="right" | real 1m4.985s<br />user 1m0.530s<br />sys 0m0.790s| align="right" | real 0m59.899s<br />user 0m57.190s<br />sys 0m0.600s|-| '''3rd Attempt'''| align="right" | real 1m5.214s<br />user 0m58.050s<br />sys 0m0.620s| align="right" | real 1m7.306s<br />user 1m0.100s<br />sys 0m0.530s|-| '''4th Attempt'''| align="right" | real 1m4.292s<br />user 0m56.880s<br />sys 0m0.700s| align="right" | real 1m4.859s<br />user 0m57.690s<br />sys 0m0.770s|-| '''5th Attempt'''| align="right" | real 0m59.811s<br />user 0m57.520s<br />sys 0m0.470s| align="right" | real 1m1.930s<br />user 0m57.210s<br />sys 0m0.540s|-| '''6th Attempt'''| align="right" | real 1m3.452s<br />user 0m57.040s<br />sys 0m0.590s| align="right" | real 1m1.532s<br />user 0m57.930s<br />sys 0m0.790s|-| '''7th Attempt'''| align="right" | real 1m0.604s<br />user 0m57.710s<br />sys 0m0.650s| align="right" | real 1m2.430s<br />user 0m57.420s<br />sys 0m0.730s|} <br /><br /><div>System: '''cdot-guru-4-1'''</div><div>File: '''gimp.tar.bz2'''</div><div>Command Used: '''time ./bzip2 -d ~/gimp.tar.bz2'''</div><div></div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''|-| '''1st Attempt'''| align="right" | real 0m18.828s<br />user 0m17.430s<br />sys 0m0.820s| align="right" | real 0m19.662s<br />user 0m17.850s<br />sys 0m0.990s|-| '''2nd Attempt'''| align="right" | real 0m19.549s<br />user 0m17.610s<br />sys 0m1.160s| align="right" | real 0m19.647s<br />user 0m17.940s<br />sys 0m0.850s|-| '''3rd Attempt'''| align="right" | real 0m19.462s<br />user 0m17.600s<br />sys 0m0.950s| align="right" | real 0m19.271s<br />user 0m17.620s<br />sys 0m0.870s|-| '''4th Attempt'''| align="right" | real 0m23.303s<br />user 0m17.800s<br />sys 0m0.850s| align="right" | real 0m22.863s<br />user 0m17.290s<br />sys 0m1.120s|-| '''5th Attempt'''| align="right" | real 0m24.544s<br />user 0m18.120s<br />sys 0m1.060s| align="right" | real 0m19.155s<br />user 0m17.560s<br />sys 0m1.030s|-| '''6th Attempt'''| align="right" | real 0m19.397s<br />user 0m17.540s<br />sys 0m0.800s| align="right" | real 0m22.998s<br />user 0m17.400s<br />sys 0m0.970s|-| '''7th Attempt'''| align="right" | real 0m19.462s<br />user 0m17.460s<br />sys 0m1.090s| align="right" | real 0m19.688s<br />user 0m17.910s<br />sys 0m0.870s|} <br /><br /><div>System: '''cdot-guru-4-1'''</div><div>File: '''gimp.tar'''</div><div>Command Used: '''time ./gzip ~/gimp.tar'''</div><div></div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''|-| '''1st Attempt'''| align="right" | real 0m32.809s<br />user 0m30.620s<br />sys 0m0.780s| align="right" | real 0m35.226s<br />user 0m33.390s<br />sys 0m0.770s|-| '''2nd Attempt'''| align="right" | real 0m43.640s<br />user 0m38.300s<br />sys 0m0.790s| align="right" | real 0m38.300s<br />user 0m34.380s<br />sys 0m0.650s|-| '''3rd Attempt'''| align="right" | real 0m45.471s<br />user 0m33.280s<br />sys 0m0.670s| align="right" | real 0m42.994s<br />user 0m36.880s<br />sys 0m0.710s|-| '''4th Attempt'''| align="right" | real 0m42.212s<br />user 0m32.690s<br />sys 0m0.510s| align="right" | real 0m41.896s<br />user 0m34.540s<br />sys 0m0.740s|-| '''5th Attempt'''| align="right" | real 0m43.309s<br />user 0m31.400s<br />sys 0m0.740s| align="right" | real 0m39.998s<br />user 0m35.240s<br />sys 0m0.840s|-| '''6th Attempt'''| align="right" | real 0m45.217s<br />user 0m31.850s<br />sys 0m0.550s| align="right" | real 0m39.942s<br />user 0m34.540s<br />sys 0m0.670s|} <div> <br /><br /><div>System: '''cdot-guru-4-1'''</div><div>File: '''gimp.tar.gz'''</div><div>Command Used: '''time ./gzip -d ~/gimp.tar.gz'''</div><div></div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''|-| '''1st Attempt'''| align="right" | real 0m3.341s<br />user 0m2.520s<br />sys 0m0.750s| align="right" | real 0m3.688s<br />user 0m3.040s<br />sys 0m0.530s|-| '''2nd Attempt'''| align="right" | real 0m3.702s<br />user 0m2.740s<br />sys 0m0.630s| align="right" | real 0m4.876s<br />user 0m2.950s<br />sys 0m0.650s|-| '''3rd Attempt'''| align="right" | real 0m3.372s<br />user 0m2.680s<br />sys 0m0.600s| align="right" | real 0m4.889s<br />user 0m2.970s<br />sys 0m0.580s|-| '''4th Attempt'''| align="right" | real 0m3.512s<br />user 0m2.760s<br />sys 0m0.470s| align="right" | real 0m4.800s<br />user 0m2.890s<br />sys 0m0.650s|-| '''5th Attempt'''| align="right" | real 0m4.413s<br />user 0m2.800s<br />sys 0m0.470s| align="right" | real 0m4.016s<br />user 0m2.930s<br />sys 0m0.620s|-| '''6th Attempt'''| align="right" | real 0m3.316s<br />user 0m2.430s<br />sys 0m0.800s| align="right" | real 0m4.033s<br />user 0m2.960s<br />sys 0m0.640s|} <br /><br /><div>System: '''cdot-guru-4-1'''</div><div>File: '''~/gimp/ (206 directories, 1204 files)'''</div><div>Command Used: '''time find ~/gimp/ -depth -print | ./cpio -ov -O ~/gimp.cpio'''</div><div></div> {| cellspacing="2" cellpadding="2" border="1"|-|| align="center" | '''w/o Thumb'''| align="center" | '''THUMB'''|-| '''1st Attempt'''| align="right" | real 0m7.311s<br />user 0m0.330s<br />sys 0m2.300s| align="right" | real 0m7.432s<br />user 0m0.290s<br />sys 0m2.480s|-| '''2nd Attempt'''| align="right" | real 0m8.064s<br />user 0m0.300s<br />sys 0m2.460s| align="right" | real 0m7.574s<br />user 0m0.230s<br />sys 0m2.510s|-| '''3rd Attempt'''| align="right" | real 0m6.415s<br />user 0m0.280s<br />sys 0m2.430s| align="right" | real 0m6.954s<br />user 0m0.300s<br />sys 0m2.510s|-| '''4th Attempt'''| align="right" | real 0m7.167s<br />user 0m0.250s<br />sys 0m2.500s| align="right" | real 0m7.129s<br />user 0m0.240s<br />sys 0m2.520s|-| '''5th Attempt'''| align="right" | real 0m8.562s<br />user 0m0.220s<br />sys 0m2.540s| align="right" | real 0m6.228s<br />user 0m0.290s<br />sys 0m2.500s|-| '''6th Attempt'''| align="right" | real 0m6.851s<br />user 0m0.210s<br />sys 0m2.580s| align="right" | real 0m7.883s<br />user 0m0.240s<br />sys 0m2.610s|-| '''7th Attempt'''| align="right" | real 0m7.382s<br />user 0m0.290s<br />sys 0m2.420s| align="right" | real 0m7.855s<br />user 0m0.320s<br />sys 0m2.430s|}</div>  '''From a test performed on 2011-11-12 by CTyler:'''  ........ -O2.. -g... -g stripped nonthumb 48576 98132 37900 thumb... 40563 93107 29932   == Project Details == Based on the benchmarks, in average, THUMB reduced the sizes about,<div>'''2.24%''' for *.rpm files,</div><div>'''7.67%''' for extracted directories, and</div><div>'''22.16%''' for executables, compared to NON-THUMB.</div><div>While it might save some disk space for executable files, it doesn't make a big different for rpm packages since rpm has it's own compressing mechanism.</div> Compared to THUMB2, In average, THUMB produced files that are about,<div>'''0.24%''' for *.rpm files,</div><div>'''0.45%''' for extracted directories, and</div><div>'''1.86%''' for executables, greater than THUMB2.</div><div>I noticed that THUMB produces files that are almost as small as THUMB2's products.</div> Just based on file size comparison, THUMB does an excellent job shrinking the file size. Performance benchmarks showed too much fluctuation in the result to provide a firm answer. At this point, my conclusion is that THUMB does not greatly effect in software's performance, but it varies depending on software. So far I've seen more improvements than decrements from THUMB. As I'm aware of that more benchmarks are required before having an concrete answer, but for now it is safe to say that THUMB for Fedora-ARM is worth further development.  
== Project News ==
This is where your regular updates will goOctober 8th, 2010 - Project started October 14th, 2010 - Major project page update with more information. In these you should discuss the status  November 5th, 2010 - To Thumb? or your workNot to Thumb? (v0.1) November 12th, your interactions 2010 - Noticed v0.1 was incorrect. Tried a different approach compiling with other members of make file. November 15th, 2010 - Figured out '''%optflags''' is located in /usr/lib/rpm/redhat/rpmrc November 20th, 2010 - Figured out that I was comparing the community (ewrong *.rpm files.gStarted all over againNovember 27th, Seneca 2010 - Correct file size comparison and Mozilla)performance benchmarks updated. December 7th, problems you have encountered2010 - Presentation regarding v0.3 to Chris Tyler and SBR600 class. December 14th, etc2010 - Project (v0.3) completed.   == Resources == ARM Architecture - http://en.wikipedia.org/wiki/ARM_architecture#Thumb
Put detailed technical information into the Project Details page (iIntroduction to ARM thumb - http://www.e., update it as you go), and save this section for news about participation in the projecteetimes.com/discussion/other/4024632/Introduction-to-ARM-thumb
1
edit