Math.floor vs Math.round vs Math.trunc vs parseInt vs Double Negation vs Bitwise XOR vs Bitwise OR vs Right Shift vs Unsigned Right Shift vs Modulo| Test case name | Result |
|---|---|
| Math.floor | |
| Math.round | |
| Math.trunc | |
| parseInt | |
| Double Negation | |
| Bitwise XOR | |
| Bitwise OR | |
| Right Shift | |
| Unsigned Right Shift | |
| Modulo |
| Test name | Executions per second |
|---|---|
| ✓ Bitwise XOR | 636,819,840 Ops/sec |
| Right Shift | 589,226,752 Ops/sec |
| Modulo | 543,684,096 Ops/sec |
| Unsigned Right Shift | 543,267,584 Ops/sec |
| Bitwise OR | 540,315,584 Ops/sec |
| Double Negation | 445,907,904 Ops/sec |
| Math.floor | 224,113,856 Ops/sec |
| Math.trunc | 223,717,920 Ops/sec |
| Math.round | 210,108,224 Ops/sec |
| parseInt | 12,499,502 Ops/sec |