Android Trace [tracking markers]

I am trying to make RecyclerView scroll smoothly. Starting with trace analysis from Android Device Monitor> DDMS> Android Systrace I thought adding custom partitions might be useful. Here you can find an example that I use for this. Can someone tell me where to find the partition logs I added? Thanks.

@Override
public CalendarMatchViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
    //        calendar_match_item  calendar_match_item
    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN_MR2) {
        Trace.beginSection("onCreateViewHolder");
    }
    View view = mInflater.inflate(R.layout.calendar_match_item, parent, false);
    CalendarMatchViewHolder vh = new CalendarMatchViewHolder(view);
    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN_MR2) {
        Trace.endSection();
    }
    return vh;
}

@Override
public void onBindViewHolder(CalendarMatchViewHolder holder, int position) {
    Match match = mMatches.get(position);
    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN_MR2) {
        Trace.beginSection("onBindViewHolder");
    }
    setOtherMatchesBasicData(match, holder);
    setOfferLayout(match, holder);

    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN_MR2) {
        Trace.endSection();
    }
}
+6
source share
1 answer

You can do this by selecting the package name in the Systrace window from the "Enter Application Trace" drop-down menu.

Systrace , : https://developer.android.com/studio/profile/systrace.html

Systrace window

+3

All Articles