JS Coverage

Written by Hunter Jansen on November 15, 2014

Last time I discussed the difficulties I was facing in finding a project to actually work on for the Linaro Performance challenge. Every package I’d decided to work on was either done already in one manner, or another or had drastically changed from its existing version. This post covers my next investigation into JSCoverage, a code coverage tool for javascript.

JSCoverage

When I ended my previous entry I had only just barely started with my investigation into JSCoverage. Following that, I decided to look for the project’s repository’s so that I could see what would be needed to bring it to Fedora both in x86 and arm64. I actually had a really difficult time finding any form of repo for JSCoverage and ended up asking my prof. Chris Tyler for a bit of help.

Without too much difficulty he found this website (In hindsight, I’m not so sure why I was having issues finding it). In the notification banner at the top, it’s stated that any future work will be done in the JSCover project here. From there I went to their github repo (here) and the first thing I noticed was that it said the project was built with Intellij IDEA, which is a popular Java IDE.

I immediately checked with github’s language statistics tool and discovered that the program was 61% java and 37% javascript. So, it looks like I’ve picked another dud, since Java’s supposed to be a build once, run anywhere approach :(. However, I decided to continue on and ensure that the project works on both architectures. I figured I’d post the steps I took to get this done.

Getting Started

The first step is to clone the repo to the machines. Note: I used exactly the same commands on both machines.

git clone https://github.com/tntim96/JSCover.git

Following that, I changed to the JSCover directory and did an ls; there were a bunch of xml files and a few references to maven, which typically means an ant build. Having an ant build is pretty common for a java project and since the repo tells me to run an ant command, I first needed to install ant on the systems:

Following that, all the dependencies should be installed, so we run the projects tests via:

ant pre-commit

This then executes all the tests to make sure you haven’t broken anything before committing. The x86 system completes in about 2:27 and the arm system takes about 3:27. Normally the discrepancy between the two times would concern me a bit, however the rest of the class has found similar results with their projects where our arm machine runs slower than the x86 machine. Because of this, I’m not too concerned as the difference should be due to the machine differences.

Now

I’m checking in with my prof how exactly to go about dealing with this on the linaro site, as it’s a different project name and arguably an entirely different project than it started off with.

The next project I’m investigating is called ZeroMQ, it’s a lightweight messaging kernel with optional asm for timer access. I’ve yet to actually start investigating, but as soon as I get going on it, I’ll be sure to post about it here.