gaaclarke

Results 267 comments of gaaclarke

Okay, I fixed it. It turns out that `[NSMutableData dataWithBytes:length:]` is 100µs slower than `[NSData dataWithBytes:length:]`. I'm not sure why, but that unfortunately means we have to use a const_cast...

Thanks for taking a look @chinmaygarde @dnfield @jason-simmons . I'll try to respond to all the feedback. There are 3 optimizations here: assets, platform channels on ios and platform channels...

Here's local testing results of the platform channel benchmarks for Android on a Pixel 4a ## before ``` I/flutter (17630): BasicMessageChannel/StandardMessageCodec/Flutter->Host/Small: 361.6 µs I/flutter (17630): BasicMessageChannel/StandardMessageCodec/Flutter->Host/Large: 2303.7 µs I/flutter (17630):...

I've removed the iOS implementation since it will take a bit more work to get it working safely with the BinaryCodec (or custom codecs). I'll land it in a separate...

> Is it beneficial to trade off the performance of small messages for larger ones? The previous implementation was already conditionalizing how data was being treated based on its size...

@jonahwilliams I duplicated that logic in the latest patch and here are the results for local testing (on Android pixel 4a): ``` I/flutter (24598): BasicMessageChannel/StandardMessageCodec/Flutter->Host/Small: 301.4 µs I/flutter (24598): BasicMessageChannel/StandardMessageCodec/Flutter->Host/Large:...

@chinmaygarde friendly ping since my response was right before a long weekend.

## Chat summary @chinmay and I had a discussion about this issue last night on Discord. Here was the takeaways, feel free to correct me if I'm misconstruing something. *...

One other thought that I didn't communicate well. The data we are actually sending here in a response is one of 4 types: 1) Ephemeral data that we can prove...

Here is some data supporting the importance of this change. (@zanderso @jonahwilliams @jiahaog ) ## Microbenchmarks Summary Here is a reminder of the microbenchmarks results: - For iOS asset loading...