TC-H, LLVM Garbage Collector

TC-H is an additional assignment.

At the end of this stage, the compiler must be able to emit garbage collector friendly LLVM IR. The collector runtime must be able to free garbage memory when necessary.

The feature is triggered by the options --llvm-gc-compute and --llvm-gc-runtime-link. The --llvm-gc-debug option can also be used to make --llvm-gc-runtime-link link the compiled module against the debug runtime instead of the default runtime.

Relevant lecture notes include 60-garbage-collection.