Script Preparation code:
Tests:
  • typeof -> string

  • Object.prototype.toString.call -> string

  • typeof -> boolean

  • Object.prototype.toString.call -> boolean

  • typeof -> object

  • Object.prototype.toString.call -> object

  • typeof -> function

  • Object.prototype.toString.call -> function

Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results
  • Test case name Result
    typeof -> string
    Object.prototype.toString.call -> string
    typeof -> boolean
    Object.prototype.toString.call -> boolean
    typeof -> object
    Object.prototype.toString.call -> object
    typeof -> function
    Object.prototype.toString.call -> function

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 9 months ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:141.0) Gecko/20100101 Firefox/141.0
Firefox 141 on Windows
View result in a separate tab
Test name Executions per second
typeof -> string 27567416.0 Ops/sec
Object.prototype.toString.call -> string 3991418.0 Ops/sec
typeof -> boolean 15027905.0 Ops/sec
Object.prototype.toString.call -> boolean 4075635.5 Ops/sec
typeof -> object 12846283.0 Ops/sec
Object.prototype.toString.call -> object 3999299.0 Ops/sec
typeof -> function 24192610.0 Ops/sec
Object.prototype.toString.call -> function 4457707.0 Ops/sec