A question about benchmarking RN Skia vs Flutter #1824
Answered
by
wcandillon
IslamRustamov
asked this question in
Q&A
Replies: 3 comments 2 replies
-
This sounds really interesting, could you share the code snippets you
used for the benchmark? there might be very useful information there.
…On Wed, Sep 6, 2023 at 9:49 AM Islam ***@***.***> wrote:
So, basically I tested 3 things - Reanimated V3, RN Skia and Flutter. What I was testing - FPS of the screen when you have 100, 500, 1500 animated rotating squares on the screen.
When I add a lot of squares for Reanimated -> Flutter shows better performance (more FPS).
But when I switch from reanimated to Skia in RN -> RN with Skia shows more FPS.
Why does Skia in RN gets more FPS?
I did test both in debug and release mode, on android and iOS -> RN was showing a better result with Skia.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
1 reply
-
This is very cool. Thank you for doing this.
The results I'm seeing match our expectations.
The benchmark results are:
1. Reanimated 3 + Skia (the whole thing is done offthread and because of
our current model we are faster than using RN views (we just have a much
more stripped-down process with no layouts etc).
2. Reanimated 3 + Views (there is a bit more that need to happen to display
an RN View (layout is one thing that jumps to mind)
3. JS animations + Skia (this is an approach that we are slowing fading
away has it blocks the JS thread pretty intensely and doesn't have the
maturity and know-how that Reanimated has).
I hope this makes sense. This is really cool, we should do more benchmarks
like this. We have many ideas for future performance improvements and
usually we try to find the use-cases to drive them.
…On Wed, Sep 6, 2023 at 10:24 AM Islam ***@***.***> wrote:
Here is a gist for RN. You can comment/uncomment the parts of it to switch
between reanimated and skia:
https://gist.github.com/IslamRustamov/b1fb27296650e8213f35db9840997f74
Here is a gist for Flutter:
https://gist.github.com/IslamRustamov/a1adcf0d1df2375d7d8af4216cdbeb8a
—
Reply to this email directly, view it on GitHub
<#1824 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AACKXVVNQP6CEM7W4E72RTTXZAXLZANCNFSM6AAAAAA4M4VH3Q>
.
You are receiving this because you commented.Message ID:
***@***.***
com>
|
Beta Was this translation helpful? Give feedback.
1 reply
-
Indeed, threads have nothing to do with performance; it's more about
leaving the thread free to do other things.
In the case of Reanimated 3, I mentioned the UI thread because it appears
to be much faster and leaves the JS thread free to perform other tasks.
Kind regards,
William
…On Wed, Sep 6, 2023 at 11:52 AM Islam ***@***.***> wrote:
You are welcome!
So, does it possibly mean that in Flutter we get less FPS because in RN
animation-related computations are done in different threads? Whereas
Flutter possibly does everything in one (not quite sure whether it's true,
will need to investigate that)
—
Reply to this email directly, view it on GitHub
<#1824 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AACKXVRUHBH5Z5R3GA6BHNDXZBBWBANCNFSM6AAAAAA4M4VH3Q>
.
You are receiving this because you commented.Message ID:
***@***.***
com>
|
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
IslamRustamov
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
So, basically I tested 3 things - Reanimated V3, RN Skia and Flutter. What I was testing - FPS of the screen when you have 100, 500, 1500 animated rotating squares on the screen.
When I add a lot of squares for Reanimated -> Flutter shows better performance (more FPS).
But when I switch from reanimated to Skia in RN -> RN with Skia shows more FPS.
Why does Skia in RN gets more FPS?
I did test both in debug and release mode, on android and iOS -> RN was showing a better result with Skia.
Beta Was this translation helpful? Give feedback.
All reactions