Both functions perform the same logic and they just vary on the base multiplication units. We can refactor the common code into a single place. Docker-DCO-1.1-Signed-off-by: Francisco Carriedo <fcarriedo@gmail.com> (github: fcarriedo) Upstream-commit: 386d300a6e07c99380a0814497cf0bc672df1e63 Component: engine