If you are compiling to binary, the compiler will take care of removing unused variables, and the names of functions will no longer be relevant. If, however, you want to distribute obfuscated source (useful, for example, for simple reverse engineering exercises given to students), you may want to clean up the code prior to distributing it.
This transformations should always be the last one to be invoked.
|--Transform||CleanUp||Transformation to run last, to clean up the generated code.|
|--CleanUpKinds||names, annotations, constants, randomize, compress, noExterns, noMain, removeUnusedFunctions, *|| Specify types of cleanup to perform Default=names,annotations,constants,randomize.
|--CleanUpDumpCallGraph||BOOLSPEC||Print the call graph computed during unused function removal as a .dot file. Default=False.|
|--CleanUpDoNotRemove||String,String,...||Comma-separated list of function names which should not be removed by the removeUnusedFunctions transformation. Default=NONE.|
|--CleanUpRoots||String,String,...||For the removeUnusedFunctions transformation, you can provide a comma-separated list of function names which are spontaneously called. Normally, this is just 'main', but if you have functions which are run spontaneously as threads, for example, and not directly reachable from main, include them here. Similarly for functions whose address are taken but which are never invoked directly. Default=main.|