الأدوات
تنظيم صفحاتك في مجموعات
يمكنك حفظ المحتوى وتصنيفه حسب إعداداتك المفضّلة.
قد يكون من الصعب معرفة مصدر مشكلة الأداء والرمز الذي يجب البدء في تحسينه. ابدأ باستخدام أدوات تساعدك في تحديد مصدر المشكلة.
أداة فحص التنسيق
استخدِم أداة فحص التنسيق لفحص التنسيق والاطّلاع على عدد عمليات إعادة التركيب.
إذا كان أداء واجهة المستخدم ضعيفًا، يكون ذلك غالبًا بسبب خطأ في الترميز يؤدي إلى إعادة إنشاء واجهة المستخدم بشكل مفرط. من ناحية أخرى، يمكن أن تمنع بعض أخطاء الترميز إعادة إنشاء واجهة المستخدم عند الحاجة إلى ذلك، ما يعني أنّ تغييرات واجهة المستخدم لا تظهر على الشاشة. يمكن أن يساعد تتبُّع عمليات إعادة التركيب في العثور على هذين النوعين من المشاكل.
إنّ إعادة التركيب في حد ذاتها ليست مشكلة، ولكن يمكن أن تكون إعادة التركيب غير المتوقّعة مشكلة.
لمزيد من المعلومات، راجِع مستندات عدد عمليات إعادة الإنشاء في "أداة فحص التصميم".
تتبُّع المقطوعات الموسيقية
استخدِم تتبُّع الإنشاء لتتبُّع الدوال القابلة للإنشاء في عملية تتبُّع النظام. تُعدّ عمليات التتبُّع غالبًا أفضل مصدر للمعلومات عند البحث لأول مرة عن مشكلة في الأداء. تسمح لك هذه الأدوات بوضع فرضية حول طبيعة المشكلة ومكان بدء البحث عنها.
مراجع إضافية
يخضع كل من المحتوى وعيّنات التعليمات البرمجية في هذه الصفحة للتراخيص الموضحّة في ترخيص استخدام المحتوى. إنّ Java وOpenJDK هما علامتان تجاريتان مسجَّلتان لشركة Oracle و/أو الشركات التابعة لها.
تاريخ التعديل الأخير: 2025-07-30 (حسب التوقيت العالمي المتفَّق عليه)
[[["يسهُل فهم المحتوى.","easyToUnderstand","thumb-up"],["ساعَدني المحتوى في حلّ مشكلتي.","solvedMyProblem","thumb-up"],["غير ذلك","otherUp","thumb-up"]],[["لا يحتوي على المعلومات التي أحتاج إليها.","missingTheInformationINeed","thumb-down"],["الخطوات معقدة للغاية / كثيرة جدًا.","tooComplicatedTooManySteps","thumb-down"],["المحتوى قديم.","outOfDate","thumb-down"],["ثمة مشكلة في الترجمة.","translationIssue","thumb-down"],["مشكلة في العيّنات / التعليمات البرمجية","samplesCodeIssue","thumb-down"],["غير ذلك","otherDown","thumb-down"]],["تاريخ التعديل الأخير: 2025-07-30 (حسب التوقيت العالمي المتفَّق عليه)"],[],[],null,["# Tooling\n\nIt can be hard to know where a performance issue lies and what code to start\noptimizing. Start by using tools to help narrow down where your issue is.\n\nLayout Inspector\n----------------\n\nUse the [Layout Inspector](/develop/ui/compose/tooling/debug#layout_inspector) to inspect your layout and see recomposition\ncounts.\n\nIf your UI has poor performance, this is often because of a coding error that\nforces your UI to be recomposed excessively. On the other hand, some coding\nerrors can prevent your UI from being recomposed when it needs to be, which\nmeans UI changes aren't showing up on the screen. Tracking recompositions can\nhelp find both of these kinds of problems.\n\nRecomposition in itself is not bad; however, unexpected recomposition can be an\nissue.\n\nFor more information, see the Layout Inspector [recomposition counts](/develop/ui/compose/tooling/debug#recomposition-counts)\ndocumentation.\n\nComposition tracing\n-------------------\n\nUse [composition tracing](/develop/ui/compose/tooling/tracing) to trace your composable functions in a system\ntrace. Traces are often the best source of information when first looking into a\nperformance issue. They allow you to form a hypothesis of what the issue is and\nwhere to start looking.\n\nAdditional Resources\n--------------------\n\n- **[App performance guide](/topic/performance/overview)**: Discover best practices, libraries, and tools to improve performance on Android.\n- **[Inspect Performance](/topic/performance/inspecting-overview):** Inspect app performance.\n- **[Benchmarking](/topic/performance/benchmarking/benchmarking-overview):** Benchmark app performance.\n- **[App startup](/topic/performance/appstartup/analysis-optimization):** Optimize app startup.\n- **[Baseline profiles](/baseline-profiles):** Understand baseline profiles."]]