Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
toggle
(version: 0)
Comparing performance of:
logical toggle vs bitwise toggle
Created:
5 years ago
by:
Guest
Jump to the latest result
Tests:
logical toggle
var x = true; for (let i = 0; i < 1000; i++) { x = !x; }
bitwise toggle
var x = 1; for (let i = 0; i < 1000; i++) { x = x^1; }
Rendered benchmark preparation results:
Suite status:
<idle, ready to run>
Run tests (2)
Previous results
Fork
Test case name
Result
logical toggle
bitwise toggle
Fastest:
N/A
Slowest:
N/A
Latest run results:
No previous run results
This benchmark does not have any results yet. Be the first one
to run it!
Related benchmarks:
Toggle hidden attribute vs toggle display:none / visibility:hidden styles
visibility vs display
classList toggle vs. classList add hide
getElementById vs id toggling class
getElementById vs id vs wrapper toggling class
Comments
Confirm delete:
Do you really want to delete benchmark?