Sliced runtime.c into more pieces (quite dirty)