On Friday, Dr. Bazzi offered me the opportunity to run some tests on some of his student's programs from the compiler project. So I have begun work on that. Basically, what I need to do is test the programs to make sure they are functioning correctly, then I need to time their execution and compile all of that data into a spreadsheet for further use. It's quite interesting how the student's compilers are tested. What I am given is a list of programs written in a simplified code that the student's compilers should be able to work with. I am also given a list of expected outputs of the student's programs. So I need to compile all the programs, run them on every test file, and make sure that their output matches the expected output. Sounds kind of tedious, right? Wrong!
Instead of doing all that work manually which would take hours and probably days, I'm doing it with a bash script. A bash script is a very high-level kind of code that is written in a computer's command prompt. Bash scripts are incredibly useful for automating tasks.
My friend and fellow researcher, Mohsen, showed me a script that he wrote in order to grade his students on their project. He ran the script and a few minutes later it had generated a huge matrix of 0s and 1s, which he could directly import into a spreadsheet for grading. I found it incredibly fitting that Computer Science students were graded in 0s and 1s.
So I'm writing a bash script to test the programs, and I'm also writing one to time the programs, so that I can take data regarding their typical run times. Although these programs are not designed to be fast, I feel that I have a large enough sample to record an typical run time for both Java and C++.
My goal for this project is to generate plentiful data that I can use for graphs on my presentation. To do so, I must congregate all of the student's programs into one spread sheet for data, which leads me to the title: I am compiling compiled compilers. Thanks for reading!
-Jeff
This title looks like an example of iterative recursion.
ReplyDeleteThe bash script helper sounds great, it would be wonderful if its application extends.