Detect Math.imul support during prototype build phase

Build in Math.imul paths or the fallbacks during the prototype object
building rather than modifying the runtime object.