Please multithread ABP using WebWorkers
Please multithread ABP using WebWorkers
When opening many tabs simultaneously (e.g. when restarting Chrome after a crash), most of the tabs get pegged with a message at the bottom, "Waiting for extension AdBlockPlus". I assume that means that only one instance of ABP can be active at a given time. It would be great if the pattern matching in ABP could be offloaded to WebWorkers, so that Chrome doesn't get blocked in this way.
Re: Please multithread ABP using WebWorkers
That approach isn't feasible as the communication with web workers has to go through asynchronous messaging. This introduces two problems:
1. Each web worker would need an own copy of the filter data, significantly increasing the memory footprint.
2. The webRequest API requires a synchronous response in order to decide whether to block a request or not, hence you cannot delegate to a web worker.
1. Each web worker would need an own copy of the filter data, significantly increasing the memory footprint.
2. The webRequest API requires a synchronous response in order to decide whether to block a request or not, hence you cannot delegate to a web worker.