Implement SIMD arithmetics

Fix #3499.

This is the other half of #5841 that was left out when I revised it to #6214.