Flutter

Performance Optimization

DevTools profiling, Isolates, compute, jank reduction, frame rendering, raster thread, app size optimization

26 면접 질문·
Senior
1

Which Flutter DevTools tool allows analyzing performance issues related to frame rendering?

답변

The Performance view (or Timeline view) in Flutter DevTools allows visualizing frames rendered by the application and identifying those exceeding the 16ms budget (60 FPS). This tool displays UI thread and raster thread activities, helping locate bottlenecks causing jank.

2

What is jank in the context of Flutter applications?

답변

Jank refers to visual stutters or hitches that occur when a frame takes more than 16ms to render (to achieve 60 FPS). This creates a non-smooth experience for the user. Jank can be caused by expensive operations on the main isolate, excessive widget rebuilds, or complex rendering operations.

3

What is the role of the UI thread and raster thread in the Flutter rendering pipeline?

답변

The UI thread executes Dart code, builds the widget tree, and generates the layer tree. The raster thread (formerly GPU thread) takes this layer tree and rasterizes it into displayable pixels. Both must complete their work in under 16ms to maintain 60 FPS. A problem on either can cause jank.

4

Why does using const constructors for widgets improve performance?

5

What is an Isolate in Dart and why is it important for performance?

+23 면접 질문

다음 면접을 위해 Flutter을 마스터하세요

모든 질문, flashcards, 기술 테스트, 코드 리뷰 연습, 면접 시뮬레이터에 접근하세요.

무료로 시작하기