Original patch by Stefan Bühler http://reviews.llvm.org/D12834
Difference between original and this one:
- fixed all failing tests
- fixed mangling for global variable outside namespace
- emit ABI tags for guards and local names (i.e. GCC ABI 10+)
- clang-format + other stylistic changes
- significantly reworked patch according to Richard's suggestions
Sema part is here: http://reviews.llvm.org/D17567