Difference between revisions of "GPU610/NullPointerException"
(→PROFILING RESULTS) |
(→Saad Mohammad:) |
||
Line 55: | Line 55: | ||
==[[User:Saad_Mohammad| Saad Mohammad]]:== | ==[[User:Saad_Mohammad| Saad Mohammad]]:== | ||
− | ===== | + | ===== Project===== |
Encrypts and decrypts images. Original project file can be found at: [https://github.com/markwatson/Image-Encrypt Image-Encrypt Github] | Encrypts and decrypts images. Original project file can be found at: [https://github.com/markwatson/Image-Encrypt Image-Encrypt Github] | ||
− | ===== | + | ===== Profiling Resource ===== |
Profiled the application using: | Profiled the application using: | ||
Line 101: | Line 101: | ||
</pre> | </pre> | ||
− | ===== | + | ===== Profiling Results ===== |
Encryption: | Encryption: | ||
Revision as of 22:09, 6 March 2013
GPU610/DPS915 | Student List | Group and Project Index | Student Resources | Glossary
Contents
NullPointerException
Team Members
Progress
Assignment 1
Philip Aziz:
- Philip Aziz - Calculating Prime Numbers
Only the inner loop would be possible to Parellelize but would still require to validate 1 prime number at a time due to need to validate against previous prime numbers.
while (count < n){
flag = 1; i = 1; checkKey = int((sqrt (prime))+1); //checks prime numbers for divisible values while(primes[i] < checkKey and flag){ if ((prime % primes[i])==0){ flag = 0; } i++; } if(flag){ primes[count] = prime; count++; } prime +=2; }
n | Elapsed Time |
---|---|
10,000 | 0 |
100,000 | 1 |
1,000,000 | 8 |
10,000,000 | 220 |
100,000,000 | 6200 |
Saad Mohammad:
Project
Encrypts and decrypts images. Original project file can be found at: Image-Encrypt Github
Profiling Resource
Profiled the application using:
SYSTEM
- Matrix
IMAGE
- JPEG Format
- 324KB
- 1598 x 982
CUSTOM MAKEFILE
# Makefile for Assignment 1 # Saad Mohammad # GCC_VERSION = 4.7.1 PREFIX = /usr/local/gcc/${GCC_VERSION}/bin/ CC = ${PREFIX}gcc CPP = ${PREFIX}g++ image_encrypt: main.o encryptjpeg.o accessjpeg.o aesencrypt.o $(CPP) -pg -ow1 main.o encryptjpeg.o accessjpeg.o aesencrypt.o -o image_encrypt rm *.o chmod +x+x+x image_encrypt main.o: main.cpp $(CPP) -c -O2 -g -pg -std=c++0x main.cpp encryptjpeg.o: encryptjpeg.cpp $(CPP) -c -O2 -g -pg -std=c++0x encryptjpeg.cpp accessjpeg.o: accessjpeg.cpp $(CPP) -c -O2 -g -pg -std=c++0x accessjpeg.cpp aesencrypt.o: aesencrypt.cpp $(CPP) -c -O2 -g -pg -std=c++0x aesencrypt.cpp clean: rm -f image_encrypt *.o
Profiling Results
Encryption:
Each sample counts as 0.01 seconds.
% cumulative self self total time seconds seconds calls us/call us/call name 53.85 0.14 0.14 5979744 0.02 0.02 aesEncrypt::ffmul(unsigned char, unsigned char) 30.77 0.22 0.08 207630 0.39 0.39 aesEncrypt::subBytes(char*) 11.54 0.25 0.03 186867 0.16 0.91 aesEncrypt::mixColumns(char*) 3.85 0.26 0.01 20763 0.48 12.52 aesEncrypt::encryptBlock(char*) 0.00 0.26 0.00 207630 0.00 0.00 aesEncrypt::shiftRows(char*) 0.00 0.26 0.00 20764 0.00 0.00 accessJpeg::hasMore() 0.00 0.26 0.00 20763 0.00 0.00 accessJpeg::accessBlock() 0.00 0.26 0.00 40 0.00 0.00 aesEncrypt::sboxify(unsigned char) 0.00 0.26 0.00 10 0.00 0.00 aesEncrypt::roundify(unsigned char) 0.00 0.26 0.00 1 0.00 0.00 _GLOBAL__sub_I__ZN10accessJpegC2Ev 0.00 0.26 0.00 1 0.00 0.00 _GLOBAL__sub_I__ZN11encryptJpeg7processEc 0.00 0.26 0.00 1 0.00 0.00 _GLOBAL__sub_I_main 0.00 0.26 0.00 1 0.00 0.00 accessJpeg::readInFile(char*) 0.00 0.26 0.00 1 0.00 0.00 accessJpeg::jumpToStart() 0.00 0.26 0.00 1 0.00 0.00 accessJpeg::writeOutFile(char*) 0.00 0.26 0.00 1 0.00 0.00 accessJpeg::~accessJpeg() 0.00 0.26 0.00 1 0.00 0.00 aesEncrypt::setTextKey(std::string) 0.00 0.26 0.00 1 0.00 0.00 aesEncrypt::expandKey() 0.00 0.26 0.00 1 0.00 0.00 aesEncrypt::~aesEncrypt()
Decryption:
Each sample counts as 0.01 seconds.
% cumulative self self total time seconds seconds calls us/call us/call name 58.97 0.23 0.23 11959488 0.02 0.02 aesEncrypt::ffmul(unsigned char, unsigned char) 25.64 0.33 0.10 207630 0.48 0.48 aesEncrypt::invSubBytes(char*) 7.69 0.36 0.03 186867 0.16 1.39 aesEncrypt::invMixColumns(char*) 5.13 0.38 0.02 20763 0.96 18.78 aesEncrypt::decryptBlock(char*) 2.56 0.39 0.01 207630 0.05 0.05 aesEncrypt::invShiftRows(char*) 0.00 0.39 0.00 20764 0.00 0.00 accessJpeg::hasMore() 0.00 0.39 0.00 20763 0.00 0.00 accessJpeg::accessBlock() 0.00 0.39 0.00 40 0.00 0.00 aesEncrypt::sboxify(unsigned char) 0.00 0.39 0.00 10 0.00 0.00 aesEncrypt::roundify(unsigned char) 0.00 0.39 0.00 1 0.00 0.00 _GLOBAL__sub_I__ZN10accessJpegC2Ev 0.00 0.39 0.00 1 0.00 0.00 _GLOBAL__sub_I__ZN11encryptJpeg7processEc 0.00 0.39 0.00 1 0.00 0.00 _GLOBAL__sub_I_main 0.00 0.39 0.00 1 0.00 0.00 accessJpeg::readInFile(char*) 0.00 0.39 0.00 1 0.00 0.00 accessJpeg::jumpToStart() 0.00 0.39 0.00 1 0.00 0.00 accessJpeg::writeOutFile(char*) 0.00 0.39 0.00 1 0.00 0.00 accessJpeg::~accessJpeg() 0.00 0.39 0.00 1 0.00 0.00 aesEncrypt::setTextKey(std::string) 0.00 0.39 0.00 1 0.00 0.00 aesEncrypt::expandKey() 0.00 0.39 0.00 1 0.00 0.00 aesEncrypt::~aesEncrypt()