in reply to Dynamically calling different functions?

Put the commands in a hash, something like this:
my %commands = ( mul => \&mul, add => \&add, set => \&set, ... );
Call them like this:
$commands{$command}($register, $param);