More perl functions transferred to common.pm