mirror of
https://github.com/gorhill/uBlock.git
synced 2024-11-02 08:52:45 +01:00
link to relevant jsperf
This commit is contained in:
parent
5d0b110aec
commit
77044c6c98
@ -386,6 +386,8 @@ vAPI.messaging.broadcast = function(message) {
|
|||||||
// "the dreaded 'uniformly slow code' case where every function takes 1%
|
// "the dreaded 'uniformly slow code' case where every function takes 1%
|
||||||
// of CPU and you have to make one hundred separate performance optimizations
|
// of CPU and you have to make one hundred separate performance optimizations
|
||||||
// to improve performance at all"
|
// to improve performance at all"
|
||||||
|
//
|
||||||
|
// http://jsperf.com/closure-no-closure/2
|
||||||
|
|
||||||
var CallbackWrapper = function(port, request) {
|
var CallbackWrapper = function(port, request) {
|
||||||
// No need to bind every single time
|
// No need to bind every single time
|
||||||
|
@ -804,6 +804,8 @@ vAPI.messaging.broadcast = function(message) {
|
|||||||
// "the dreaded 'uniformly slow code' case where every function takes 1%
|
// "the dreaded 'uniformly slow code' case where every function takes 1%
|
||||||
// of CPU and you have to make one hundred separate performance optimizations
|
// of CPU and you have to make one hundred separate performance optimizations
|
||||||
// to improve performance at all"
|
// to improve performance at all"
|
||||||
|
//
|
||||||
|
// http://jsperf.com/closure-no-closure/2
|
||||||
|
|
||||||
var CallbackWrapper = function(messageManager, channelName, listenerId, requestId) {
|
var CallbackWrapper = function(messageManager, channelName, listenerId, requestId) {
|
||||||
this.callback = this.proxy.bind(this); // bind once
|
this.callback = this.proxy.bind(this); // bind once
|
||||||
|
Loading…
Reference in New Issue
Block a user