Add some Hprm functions and a small logging tweak