Fix gdb_wrapper to work with C++ functions.

Fix two issues associated with spliting instructions that are within
functions whose signatures contain comma and colon characters (e.g.
templates).
Cache two gdb lookups that can be slow for large programs.
Merge pull request #2 from allanlw/master

Fix two issues with the gdb wrapper.