Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Baseline Profilesでアプリのパフォーマンスを向上させる / Improve app performance with Baseline Profiles

Nabe
June 22, 2022

Baseline Profilesでアプリのパフォーマンスを向上させる / Improve app performance with Baseline Profiles

potatotips #78 iOS/Android開発Tips共有会
https://potatotips.connpass.com/event/248347/

Nabe

June 22, 2022
Tweet

More Decks by Nabe

Other Decks in Programming

Transcript


  1. QPUBUPUJQTJ04"OESPJE։ൃ5JQTڞ༗ձ
    ,B[VLJ8BUBOBCF
    #BTFMJOF1SPGJMFTͰ
    ΞϓϦͷύϑΥʔϚϯεΛ޲্ͤ͞Δ

    View full-size slide

  2. 1SPGJMF
    w ͳ΂
    w 5XJUUFS!/BCF$PUU
    w (JU)VC/6NFSP"OE%FW
    w גࣜձࣾ͸ͯͳ
    w "OESPJEJ04BQQMJDBUJPOFOHJOFFS

    View full-size slide

  3. એ఻
    w ͸ͯͳͰ͸J04"OESPJEΞϓϦΤϯδχΞΛ࠾༻͍ͯ͠·͢ʂ
    w ΧδϡΞϧͳ໘ஊ΋Ͱ͖ΔͷͰͥͻؾܰʹ͓੠͕͚͍ͩ͘͞ʂ
    https://open.talentio.com/r/1/c/hatena/pages/28838

    View full-size slide

  4. ࠓ೔࿩͢͜ͱ
    w #BTFMJOF1SP
    fi
    MFTͱ͸Կ͔
    w #BTFMJOF1SP
    fi
    MFTͷಋೖͱͭ·͖ͣϙΠϯτ
    w #BTFMJOF1SP
    fi
    MFTͰͲͷఔ౓ύϑΥʔϚϯε͕վળ͞ΕΔͷ͔

    View full-size slide

  5. #BTFMJOF1SPGJMFTͱ͸Կ͔

    View full-size slide

  6. #BTFMJOF1SPGJMFTͱ͸Կ͔
    w "35 "OESPJE3VOUJNF
    ͕ϓϦίϯύΠϧ͢Δͱ͖ʹ࢖༻͢ΔΞϓϦͷΫϥ
    εͱϝιουͷϦετ
    w ΞϓϦʹόϯυϧ͢Δ͜ͱͰىಈ࣌ؒ΍ϨϯμϦϯά͕վળ͞ΕΔ
    w "OESPJEd࠷৽04·ͰʹޮՌ͕͋Δ
    w $MPVE1SP
    fi
    MFͱͯ͠(PPHMF1MBZ͕ಉ͡Α͏ͳ࢓૊ΈΛఏڙ͍ͯ͠Δ͕ɺ
    ͪ͜Β͸ఏڙ͞ΕΔ·Ͱ͕͔͔࣌ؒΔͨΊʹϦϦʔεεύϯ͕୹͍ΞϓϦͰ
    ͸ԸܙΛड͚Δ͜ͱ͕Ͱ͖ͳ͍

    View full-size slide

  7. #BTFMJOF1SPGJMFTͷಋೖ

    View full-size slide

  8. #BTFMJOF1SPGJMFTͷಋೖ
    w BQQϞδϡʔϧʹ1SP
    fi
    MF*OTUBMMFSͷґଘΛ௥Ճ

    View full-size slide

  9. #BTFMJOF1SPGJMFTͷಋೖ
    w .BDSPCFODINBSLͷϞδϡʔϧΛ௥Ճ

    View full-size slide

  10. #BTFMJOF1SPGJMFTͷಋೖ
    w ⚠ͭ·͖ͣϙΠϯτ
    w QSPEVDU'MBWPST͕BQQϞδϡʔϧʹ͋Δ৔߹͸CFODINBSLͷϞδϡʔϧͰ΋ઃఆ͕ඞཁ
    w BQQϞδϡʔϧͷQSPEVDU'MBWPSTΛCFODINBSLϞδϡʔϧʹ΋ಉ༷ͷఆٛ͢Δɺ΋͘͠
    ͸NBUDIJOH'BMMCBDLTΛ࢖ͬͯ৽نͷ
    fl
    BWPSΛ௥Ճ͢Δ

    View full-size slide

  11. #BTFMJOF1SPGJMFTͷಋೖ
    w #BTFMJOF1SP
    fi
    MFTΛੜ੒͢Δςετͷ௥Ճ

    View full-size slide

  12. #BTFMJOF1SPGJMFTͷಋೖ
    w ௥Ճͨ͠#BTFMJOF1SP
    fi
    MFTΛੜ੒͢ΔςετΛΤϛϡϨʔλͰ࣮ߦ
    w ⚠ͭ·͖ͣϙΠϯτ
    w (PPHMF"1*͔ͭ"OESPJEҎ߱ͷΤϛϡϨʔλΛ࢖༻ͯ͠ɺ࣮ߦલʹ
    adb rootͰSPPUԽ͓ͯ͘͠ඞཁ͕͋Δ

    View full-size slide

  13. #BTFMJOF1SPGJMFTͷಋೖ
    w ⚠ͭ·͖ͣϙΠϯτ
    w 1SP
    fi
    MFTΛੜ੒͢ΔCVJME5ZQFͰ͸೉ಡԽΛແޮʹ͢Δඞཁ͕͋Δ
    w ΞϓϦϦϦʔε࣌ͷ೉ಡԽ͸֎ͯ͠͸͍͚ͳ͍

    View full-size slide

  14. #BTFMJOF1SPGJMFTͷಋೖ
    w ੜ੒͞Εͨ1SP
    fi
    MFTΛϓϩδΣΫτʹQVMM͢Δ
    w ࣮ߦϩάʹίϚϯυ͕ग़ྗ͞ΕΔͷͰɺͦͷίϚϯυ͔Βੜ੒͞ΕͨϑΝ
    ΠϧΛऔಘͯ͠BQQTSDNBJOʹCBTFMJOFQSPGUYUͷ໊લͰ഑ஔ͢Δ

    View full-size slide

  15. #BTFMJOF1SPGJMFTͷಋೖ
    w .BDSPCFODINBSLͰվળ͞Ε͔ͨͷ֬ೝ
    w ௨ৗͷϦϦʔεϏϧυͰ͸#BTFMJOF1SP
    fi
    MFT͸༗ޮʹͳΒͳ͍ͷͰɺ
    .BDSPCFODINBSLͰܭଌͯ֬͠ೝ͢Δඞཁ͕͋Δ
    w ⚠ͭ·͖ͣϙΠϯτ
    w "OESPJE-ͱ͸.BDSPCFODINBSLΛ༻͍ͨ1SP
    fi
    MFTͷ࣮ߦʹ
    ରԠ͍ͯ͠ͳ͍ͷͰ"OESPJEdͰ࣮ߦ͢Δඞཁ͕͋Δ
    ݱࡏ

    View full-size slide

  16. #BTFMJOF1SPGJMFTͰ
    Ͳͷఔ౓ύϑΥʔϚϯε͕վળ͞ΕΔͷ͔

    View full-size slide

  17. #BTFMJOF1SPGJMFTͰͲͷఔ౓ύϑΥʔϚϯε͕վળ͞ΕΔͷ͔
    w "OESPJE7JFXͷϓϩδΣΫτ

    View full-size slide

  18. #BTFMJOF1SPGJMFTͰͲͷఔ౓ύϑΥʔϚϯε͕վળ͞ΕΔͷ͔
    w 'VMM+FUQBDL$PNQPTFͷϓϩδΣΫτ
    w ͜Ε͸#BTFMJOF1SP
    fi
    MFTͷ׬શແޮͱ༗ޮͷൺֱͰɺ+FUQBDL$PNQPTFͷϥΠϒϥ
    Ϧʹؚ·ΕΔ1SP
    fi
    MFT΋༗ޮʹͳΔͷͰ࣮ࡍ͸͜͜·Ͱ͕ࠩ͋ΔΘ͚Ͱ͸ͳ͍
    w "OESPJE04ͷҰ෦Ͱ͋Δ7JFXͱ͸ҟͳΓɺϥΠϒϥϦͰ͋Δ+FUQBDL$PNQPTF
    ͸1SP
    fi
    MFTͷ࢓૊Έʹ৐Βͳ͍ͱύϑΥʔϚϯεͷ໰୊͕ى͖Δ

    View full-size slide

  19. ·ͱΊ
    w #BTFMJOF1SP
    fi
    MFTͰىಈ࣌ؒͳͲͷύϑΥʔϚϯεΛվળͰ͖Δ
    w େ͖͘վળ͠ͳ͍৔߹΋͋ΔͷͰ͖ͪΜͱଌఆ͢Δඞཁ͕͋Δ
    w ϥΠϒϥϦͷߋ৽΍࣮૷͕มΘΔͨͼʹ#BTFMJOF1SP
    fi
    MFTΛੜ੒͢Δඞཁ͕͋Δ
    w ϦϦʔεલʹੜ੒͢ΔϑϩʔΛઃ͚Δ͜ͱʹͳΓͦ͏
    w 45"3;&30͞Μ͕Ҏલ#BTFMJOFT1SP
    fi
    MFTΛੜ੒͢Δ"DUJPOTΛ࣮૷͍ͯ͠
    ͨͷͰࢀߟʹͰ͖Δ
    w IUUQTHJUIVCDPN45"3;&30%BHBTIJ"QQQVMM

    View full-size slide

  20. ࢀߟ
    w IUUQTEFWFMPQFSBOESPJEDPNUPQJDQFSGPSNBODF
    CBTFMJOFQSP
    fi
    MFT
    w IUUQTEFWFMPQFSBOESPJEDPNUPQJDQFSGPSNBODF
    CFODINBSLJOHNBDSPCFODINBSLPWFSWJFX
    w IUUQTZPVUVCF%:E)-R-7TQ:
    w IUUQTBOESPJEEFWFMPQFSTHPPHMFCMPHDPN
    JNQSPWJOHBQQQFSGPSNBODFXJUICBTFMJOFIUNM
    w IUUQTHJUIVCDPNBOESPJEQFSGPSNBODFTBNQMFT

    View full-size slide