Major refactoring and renaming of LDR