Minor inlining and code flow improvements to reduce memory usage
Updated includes
Fix getLinkDesc