mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
std::shared_from_this is actually incredibly slow, and dominates the cost of host buffer allocation at 20x more expensive than the memcpy. We can remove the usage of shared_from_this by making an internal class hold the actual allocation/buffer state instead. ### Before  146 ms / 647ms = ~20% ### After 33 ms / 540 ms = ~6% 