Major refactor of CG.
Major refactor of CG.

Refactoring for readability:
 * separated the functionality into functions
  * main handles program flow, arg checking
  * countBases counts total bases
  * calculateProfile does the actual profile calculation

Also, we now open the file mmapped instead of reading. This allows the
virtual memory system to reuse memory better and prevents copying into
longstr constantly.

On a 15MB gbk file this reduces from ~ 3.6s to ~ 0.7s. Tested that it
produces the exact same output as before.

re #617

NProfileAnalysisComputationalTool/npact,NProfileAnalysisComputationalTool/npact,victor-lin/npact,NProfileAnalysisComputationalTool/npact,victor-lin/npact,victor-lin/npact,victor-lin/npact,victor-lin/npact,NProfileAnalysisComputationalTool/npact,NProfileAnalysisComputationalTool/npact