Test case name | Result |
---|---|
Lodash clamp | |
Manual Math.min Math.max | |
CLAMP_INT | |
branchClamp |
Test name | Executions per second |
---|---|
Lodash clamp | 4970830.0 Ops/sec |
Manual Math.min Math.max | 2711311.0 Ops/sec |
CLAMP_INT | 7044673.0 Ops/sec |
branchClamp | 7078506.0 Ops/sec |