function pointers replaced by normal functions in local module code
removed Regs struct, function pointers functions replaced by normal functions in local module