Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
ARTのメモリ管理
Search
haru067
April 25, 2015
Programming
8
15k
ARTのメモリ管理
haru067
April 25, 2015
Tweet
Share
More Decks by haru067
See All by haru067
Jetpack Compose: 効果的なComposable関数のAPI設計
haru067
2
6.2k
いかにしてアプリの起動時間を改善するか
haru067
3
2k
REALITY Androidにおけるマルチモジュール移行
haru067
0
1.3k
Immutable data holder
haru067
1
1.1k
Other Decks in Programming
See All in Programming
SymfonyCon Vienna 2025: Twig, still relevant in 2025?
fabpot
3
1.2k
Effective Signals in Angular 19+: Rules and Helpers
manfredsteyer
PRO
0
110
PHPで学ぶプログラミングの教訓 / Lessons in Programming Learned through PHP
nrslib
3
290
PHPUnitしか使ってこなかった 一般PHPerがPestに乗り換えた実録
mashirou1234
0
210
「とりあえず動く」コードはよい、「読みやすい」コードはもっとよい / Code that 'just works' is good, but code that is 'readable' is even better.
mkmk884
3
470
Spatial Rendering for Apple Vision Pro
warrenm
0
110
rails stats で紐解く ANDPAD のイマを支える技術たち
andpad
1
290
Recoilを剥がしている話
kirik
5
6.8k
create_tableをしただけなのに〜囚われのuuid編〜
daisukeshinoku
0
260
クリエイティブコーディングとRuby学習 / Creative Coding and Learning Ruby
chobishiba
0
3.9k
Amazon S3 NYJavaSIG 2024-12-12
sullis
0
100
From Translations to Multi Dimension Entities
alexanderschranz
2
130
Featured
See All Featured
Fontdeck: Realign not Redesign
paulrobertlloyd
82
5.3k
Speed Design
sergeychernyshev
25
670
4 Signs Your Business is Dying
shpigford
181
21k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
28
4.4k
Agile that works and the tools we love
rasmusluckow
328
21k
No one is an island. Learnings from fostering a developers community.
thoeni
19
3k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
10
810
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
33
2k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
38
1.9k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
2
170
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
48
2.2k
Reflections from 52 weeks, 52 projects
jeffersonlam
347
20k
Transcript
"35ͷϝϞϦཧ %SPJE,BJHJ!IBSV
ࣗݾհ ˔ 5XJUUFSΫϥΠΞϯτ 4IPPUJOH4UBSͷ։ൃऀ !IBSV
ࣗݾհ ˔ 5XJUUFSΫϥΠΞϯτ 4IPPUJOH4UBSͷ։ൃऀ ʢͨ·ʹਅ໘ͳΛʣ !IBSV
"OESPJEͷ($ͷྺ࢙ Y %BMWJL7. "35
"OESPJEͷ($ͷྺ࢙ 'SPZP ˔ ϚʔΫεΠʔϓ($ ˔ ($தΞϓϦέʔγϣϯ͕ఀࢭͯ͠͠·͏ ʢ458ɼ4UPQ5IF8PSMEʣ Y
%BMWJL7. "35
"OESPJEͷ($ͷྺ࢙ (JOHFSCSFBE ˔ .PTUMZ$PODVSSFOU($ ˔ ϚʔΫεΠʔϓ($ΛΞϓϦέʔγϣϯͱ ΄΅ฒߦʹ࣮ߦɽఀࢭ࣌ؒେ͖͘վળ Y
%BMWJL7. "35
"OESPJEͷ($ͷྺ࢙ Y*$4 +FMMZ#FBO ˔ େ͖ͳมߋͳ͠ ˔ .PTUMZ$PODVSSFOU($ ʢฒߦϚʔΫεΠʔϓ($ʣ
Y %BMWJL7. "35
"OESPJEͷ($ͷྺ࢙ ,JULBU ˔ "35ͳΔϥϯλΠϜ͕ग़ݱ ˔ σϑΥϧτ·ͩ%BMWJL7. Y
%BMWJL7. "35
"OESPJEͷ($ͷྺ࢙ -PMMJQPQ ˔ "35͕σϑΥϧτʹɼ%BMWJLരൃ࢛ࢄ ˔ ϥϯλΠϜ͕ସΘͬͯ($ͱ͔৭ʑͱมΘͬͨ Y
%BMWJL7. "35
Կ͕มΘͬͨͷ͔ʁ
ฒߦ($ͷఀࢭ࣌ؒ
%BMWJL7. ˔ ϧʔτεΩϟϯͱ࠶ϚʔΫͰΞϓϦ͕ఀࢭ͢Δ "35 ˔ ϧʔτεΩϟϯͱ࠶ϚʔΫͷҰ෦Λฒߦʹॲཧ ͕͜͜มΘͬͨɿฒߦ($ͷఀࢭՕॴ ϧʔτ εΩϟϯ ϚʔΫ
࠶ϚʔΫ εΠʔϓ ϧʔτ εΩϟϯ ϚʔΫ ࠶ϚʔΫ εΠʔϓ
%BMWJL7. ˔ ϧʔτεΩϟϯͱ࠶ϚʔΫͰΞϓϦ͕ఀࢭ͢Δ "35 ˔ ϧʔτεΩϟϯͱ࠶ϚʔΫͷҰ෦Λฒߦʹॲཧ ͕͜͜มΘͬͨɿฒߦ($ͷఀࢭՕॴ ϧʔτ εΩϟϯ ϚʔΫ
࠶ϚʔΫ εΠʔϓ ϧʔτ εΩϟϯ ϚʔΫ ࠶ϚʔΫ εΠʔϓ dϛϦඵ͙Β͍
%BMWJL7. ˔ ϧʔτεΩϟϯͱ࠶ϚʔΫͰΞϓϦ͕ఀࢭ͢Δ "35 ˔ ϧʔτεΩϟϯͱ࠶ϚʔΫͷҰ෦Λฒߦʹॲཧ ͕͜͜มΘͬͨɿฒߦ($ͷఀࢭՕॴ ϧʔτ εΩϟϯ ϚʔΫ
࠶ϚʔΫ εΠʔϓ ϧʔτ εΩϟϯ ϚʔΫ ࠶ϚʔΫ εΠʔϓ
%BMWJL7. ˔ ϧʔτεΩϟϯͱ࠶ϚʔΫͰΞϓϦ͕ఀࢭ͢Δ "35 ˔ ϧʔτεΩϟϯͱ࠶ϚʔΫͷҰ෦Λฒߦʹॲཧ ͕͜͜มΘͬͨɿฒߦ($ͷఀࢭՕॴ ϧʔτ εΩϟϯ ϚʔΫ
࠶ϚʔΫ εΠʔϓ ϧʔτ εΩϟϯ ϚʔΫ ࠶ϚʔΫ εΠʔϓ ϛϦඵ͙Β͍
"35ͷฒߦ($εΰΠʂ
ฒߦ͡Όͳ͍΄͏ʁ ˔ 458($ ˔ MPHDBUʹग़ͯ͘Δ($@'03@"--0$͜Ε ˔ ϝϞϦྖҬ͕ෆ͢Δͱൃੜ ˔ ฏؾͰΞϓϦ͕ඵࢭ·ͬͨΓ͢Δ ൃੜ͢Δͱ໌Β͔ʹϠό͍
ฒߦ͡Όͳ͍΄͏ʁ ˔ 458($ ˔ MPHDBUʹग़ͯ͘Δ($@'03@"--0$͜Ε ˔ ϝϞϦྖҬ͕ෆ͢Δͱൃੜ ˔ ฏؾͰΞϓϦ͕ඵࢭ·ͬͨΓ͢Δ ൃੜ͢Δͱ໌Β͔ʹϠό͍
ϩάݟΔͱׂͱൃੜͯͨ͠Γ͢Δ
ʀʅЧʆ
458($ͷൃੜݪҼͦͷ̍ ˔ அยԽʹΑΔϝϞϦׂͯͷࣦഊ ʮۭ͍ͯΔͱ͜Ζνϥϗϥ͋Δ͚ͲೖΒͳ͍ʯ ˔ ΞϓϦέʔγϣϯ͝ΈͷճऩΛͨͳ͍ͱ͍ ͚ͳ͍ ώʔϓ ۭ͖ྖҬ ༻த
PCK ʁ
ʁ
σϑϥά͢Ε͍͍͡ΌΜ ˔ σϑϥάʹੌ͍͕͔͔࣌ؒΔ ˔ ώʔϓΛԿεΩϟϯ͢Δඞཁ͕͋Δ ˔ σϑϥά͍ͯ͠ΔؒΞϓϦέʔγϣϯ͕ఀࢭ ˔ ͱͯͭΒ͍
"35Ͳ͏ͯ͠Δͷ ˔ େ͖͍ΦϒδΣΫτ͕ॾѱͷࠜݯ ώʔϓ ۭ͖ྖҬ ༻த PCK
"35Ͳ͏ͯ͠Δͷ ˔ େ͖͍ΦϒδΣΫτ͕ॾѱͷࠜݯ ʮσϒిंʹΔͳʯ ώʔϓ ۭ͖ྖҬ ༻த PCK
͕͜͜มΘͬͨɿஅยԽରࡦ ˔ େ͖͍ΦϒδΣΫτΛผͷྖҬͰཧ ʮσϒઐ༻ं྆Λͭ͘Ζ͏ʯ ˔ -BSHF0CKFDU4QBDFʢ-04ʣ ௨ৗ༻ ۭ͖ྖҬ ༻த Ͱ͔͍ͭΒʢେ͖Ίͷྻͱ͔ʣ༻
"35͕ΜͬͯΔ
458($ͷൃੜݪҼͦͷ̎ ˔ ϝϞϦׂ͕ܹͯͯ͘͠ฒߦ($͕͍͔ͭͳ͍ ΞϓϦ࣮ߦ
458($ͷൃੜݪҼͦͷ̎ ˔ ϝϞϦׂ͕ܹͯͯ͘͠ฒߦ($͕͍͔ͭͳ͍ ฒߦ($ ΞϓϦ࣮ߦ
458($ͷൃੜݪҼͦͷ̎ ˔ ϝϞϦׂ͕ܹͯͯ͘͠ฒߦ($͕͍͔ͭͳ͍ ฒߦ($ ΞϓϦ࣮ߦ ΞϓϦ࣮ߦ
458($ͷൃੜݪҼͦͷ̎ ˔ ϝϞϦׂ͕ܹͯͯ͘͠ฒߦ($͕͍͔ͭͳ͍ ฒߦ($ ΞϓϦ࣮ߦ ΞϓϦ࣮ߦ ฒߦ($
458($ͷൃੜݪҼͦͷ̎ ˔ ϝϞϦׂ͕ܹͯͯ͘͠ฒߦ($͕͍͔ͭͳ͍ ฒߦ($ ΞϓϦ࣮ߦ ΞϓϦ࣮ߦ ฒߦ($ ϝϞϦਚ͖·ͨ͠
458($ͷൃੜݪҼͦͷ̎ ˔ ϝϞϦׂ͕ܹͯͯ͘͠ฒߦ($͕͍͔ͭͳ͍ ฒߦ($ ΞϓϦ࣮ߦ ΞϓϦ࣮ߦ ฒߦ($ ϝϞϦਚ͖·ͨ͠ 458($
458($ͷൃੜݪҼͦͷ̎ ˔ ϝϞϦׂ͕ܹͯͯ͘͠ฒߦ($͕͍͔ͭͳ͍ ฒߦ($ ΞϓϦ࣮ߦ ΞϓϦ࣮ߦ ฒߦ($ ϝϞϦਚ͖·ͨ͠ 458($
ฒߦ($ૣΊʹΕ͍͍͡ΌΜ ˔ ͍͍ͩͨ͋ͬͯΔ ˔ "35%BMWJLΑΓݡ͘ฒߦ($Λ࣮ߦͯ͠Δ ˔ جຊతʹۭ͖ྖҬ͕ҰఆΛ͑ͨΒ($ ˔ "35ϝϞϦׂͯසͱ͔ߟྀͭͭ͠($
"35͕ΜͬͯΔ
"35ͷఀࢭ࣌ؒ·ͱΊ ˔ ฒߦ($ͰɼΞϓϦΛఀࢭ্ͤͨ͞ͰͷॲཧΛݮ ˔ 458($ͷൃੜසΛ͑Δ ˔ -BSHF0CKFDU4QBDFʹΑΔஅยԽରࡦ ˔ ΑΓ͜·ʹɼલͬͯฒߦ($ ฏۉఀࢭ࣌ؒΛ͘
࣌ؒͷఀࢭΛ͑Δ
ΊͰͨ͠ʁ
˔ 458($ͷൃੜ͑ΒΕΔ ˔ εϧʔϓοτʢ࣮ߦ࣌ؒʣѱ͘ͳΔ ΉΈʹฒߦ($Λ࣮ߦ͍͍ͯ͠ͷ͔ʁ
˔ 458($ͷൃੜ͑ΒΕΔ ˔ εϧʔϓοτʢ࣮ߦ࣌ؒʣѱ͘ͳΔ ΉΈʹฒߦ($Λ࣮ߦ͍͍ͯ͠ͷ͔ʁ ࣮ߦ࣌ؒͬͪ͜ͷ΄͏͕͍
εϧʔϓοτ
͕͜͜มΘͬͨɿฒྻ($ ˔ ($ͷॲཧΛฒྻ࣮ߦͯ͠ߴԽ ˔ ϚϧνίΞ$16ࡌ͕૿͑ͯΔ͜ͱͩ͠ ˔ ͷ($ʹ͔͔Δ࣌ؒΛॖ ˔ ࠶ϚʔΫͷఀࢭ͢Δॲཧ͘ͳͬͯخ͍͠ ϧʔτ
εΩϟϯ ϚʔΫ ࠶ϚʔΫ εΠʔϓ
͕͜͜มΘͬͨɿฒྻ($ ˔ ($ͷॲཧΛฒྻ࣮ߦͯ͠ߴԽ ˔ ϚϧνίΞ$16ࡌ͕૿͑ͯΔ͜ͱͩ͠ ˔ ͷ($ʹ͔͔Δ࣌ؒΛॖ ˔ ࠶ϚʔΫͷఀࢭ͢Δॲཧ͘ͳͬͯخ͍͠
͕͜͜มΘͬͨɿੈผ($ ˔ ଟ͘ͷΦϒδΣΫτ໋Ͱ͋Δɼͱ͍͏ԾઆΛ ར༻ͨ͠($ ˔ 4UJDLZNBSLCJUT($ ˔ લճͷ($Ҏ߱ʹ࡞ΒΕͨ͝Έ͚ͩճऩ ($ ($
͕͜͜มΘͬͨɿੈผ($ ˔ ଟ͘ͷΦϒδΣΫτ໋Ͱ͋Δɼͱ͍͏ԾઆΛ ར༻ͨ͠($ ˔ 4UJDLZNBSLCJUT($ ˔ લճͷ($Ҏ߱ʹ࡞ΒΕͨ͝Έ͚ͩճऩ ($ ($
($ର ($ର֎
͕͜͜มΘͬͨɿੈผ($ ˔ ଟ͘ͷΦϒδΣΫτ໋Ͱ͋Δɼͱ͍͏ԾઆΛ ར༻ͨ͠($ ˔ 4UJDLZNBSLCJUT($ ˔ લճͷ($Ҏ߱ʹ࡞ΒΕͨ͝Έ͚ͩճऩ ($ ($
($ର ($ର֎ ϐϯϙΠϯτͰ͝ΈΛճऩ
͕͜͜มΘͬͨɿΞϩέʔλ ˔ %BMWJL7.ɿEMNBMMPD ˔ HMJCDͷNBMMPDʢͷେݩʹͳͬͨΞϩέʔλʣ ˔ ฒߦϝϞϦׂͯϩοΫͰഉଞ੍ޚ ˔ "35ɿ3PT"MMPD ˔
"35ಠࣗͷϝϞϦΞϩέʔλ ˔ 4FHSFHBUFEGSFFMJTU ˔ ฒߦϝϞϦׂͯʹରԠ
ฒߦϝϞϦׂͯ ώʔϓ ۭ͖ྖҬ ༻த εϨου εϨου
ฒߦϝϞϦׂͯ ώʔϓ ۭ͖ྖҬ ༻த εϨου new Object(); εϨου new Object();
·ͱΊ ˔ "35͕ΜͬͯΔ
·ͱΊ ˔ "35͕ΜͬͯΔ ˔ ͱ͍͏ΑΓ%BMWJL7.͕ΨόΨόͩͬͨʁ ˔ ͱʹ͔͘ؤுͬͯΔɼࠓޙʹظ
·ͱΊ ˔ ฒߦ($ͷఀࢭՕॴ͕ΑΓ͘ͳͬͨ ˔ 458($ͷൃੜස͕͘ͳͬͨ ˔ -BSHF0CKFDU4QBDFʹΑΔஅยԽରࡦ ˔ ͜·ʹฒߦ($ ˔
εϧʔϓοτվળ ˔ ฒߦ($ɼੈผ($ ˔ ϝϞϦׂͯͷฒߦॲཧʹରԠ ˔ 3PT"MMPD