You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert
#ã¯ããã« Unity2019ããã¬ãã¼ã¸ã³ã¬ã¯ã·ã§ã³çºçæã®ã¹ãã¤ã¯ãæ¹åããæ©è½[ã¤ã³ã¯ãªã¡ã³ã¿ã« GC]ããªãªã¼ã¹ããã¾ããã ä¸è¦ãªã¡ã¢ãªç¢ºä¿ã«ããã¬ãã¼ã¸ã³ã¬ã¯ã·ã§ã³çºçæã®ã¹ãã¤ã¯ã¯åé¿å¯è½ããããã¾ãããã [ããã¼ã¸ãã¼ãã®æ¡å¼µãçºçãããã¨ã«ããã¡ã¢ãªã®æ¯æ¸] & [ã¡ã¢ãªã確ä¿ã§ããªãã£ãå ´åã®ã¯ã©ãã·ã¥] ã«é¢ãã¾ãã¦ã¯ã[ä¸è¦ãªã¡ã¢ãªã確ä¿ããªã]ãã¨ãæèããªããã°ãä½ãçºçãã¾ãã ä»åã®è¨äºã§ã¯ã[ä¸è¦ãªã¡ã¢ãªå²ãå½ã¦(GC Alloc)]ãé¿ããçºã®æ¹æ³ãå°ã éã«ãªãã¾ãããè¦ç´ãããã¾ããã çæ§ã®å½¹ã«ç«ã¦ã¾ãã¨å¹¸ãã§ããããï¼ #ã¬ãã¼ã¸ã³ã¬ã¯ã·ã§ã³ããã³ããã¼ã¸ãã¼ãã®æ¡å¼µã«é¢ãã¾ã㦠ã¤ã³ã¹ã¿ã³ã¹ã®çæãæååé£çµãªã©ã®è¦å ã§ãªãã¸ã§ã¯ããçæãããéã«[GC Alloc]ãçºçããããã«ãã確ä¿ãããã¡ã¢ãªã¯ããã¼ã¸ãã¼ãã¨ããé åã«å²ãå½ã¦ã¾ãã
ãé人ãæããWebããã©ã¼ãã³ã¹ãã¥ã¼ãã³ã° ãISUCONããå¦ã¶é«éåã®å®è·µãã¨ããæ¬ã6åã®å ±èã§å·çãã¾ãããæè¡è©è«ç¤¾ããããã2022å¹´6æ4æ¥çºå£²äºå®ã§ããé»åçãã§ã¾ãã gihyo.jp Amazon ã¯ãã¡ãã é人ãæããWebããã©ã¼ãã³ã¹ãã¥ã¼ãã³ã° ãISUCONããå¦ã¶é«éåã®å®è·µ ä½è :è¤å ä¿ä¸é,é¦¬å ´ ä¿å½°,ä¸è¥¿ 建ç»,é·é é åº,éå éå,èé ç¿æè¡è©è«ç¤¾Amazon ã¿ã¤ãã«ã®éããISUCON ã§åºé¡ããããããªWebãµã¼ãã¹ãä¾ã«ãã¦ãWebãµã¼ãã¹ã®ãµã¼ãã¼ãµã¤ãããã©ã¼ãã³ã¹ãã¥ã¼ãã³ã°ãæåããå 容ã§ããé称ãISUCONæ¬ãã¨å¼ãã§ãã ããã 2020å¹´ã®æ«ã«ãæè¡è©è«ç¤¾ããããWebãµã¼ãã¹é«éå à ISUCONã«é¢ããæ¸ç±ãå·çãã¾ããããã¨è¤åã¾ã§ãèªããããã ããã®ãçºç«¯ã§ããã æ¸ãããæ°æã¡ã¯ãã£ããã®ã®ãå 容çã«ã¨ã¦
ããã«ã¡ã¯ãã¢ããªã±ã¼ã·ã§ã³åºç¤ãã¼ã ã®éæ¨(@a_o_k_i_n_g)ã§ããå æ¥è¦ªç¥ãããææ¯ããæãã¤ããããã®ã§ MySQL ã® JOIN ã®ãã¨ãèãã¦å¿ã®å¹³éãä¿ã£ã¦ãã¾ããã ãµã¤ãã¦ãºã®è£½åã®ã²ã¨ã¤ã§ãã kintone ã¯ãã¼ãºã«å¿ãã¦èªç±ã«æ¥åã¢ããªã®ãããªãã®ãæ軽ã«ä½ããã¨ãã§ãããã¼ã¿ã®æ¤ç´¢æ¡ä»¶ãã½ã¼ãæ¡ä»¶ãç´°ããã«ã¹ã¿ãã¤ãºå¯è½ã§ãæ§ã ãªã¬ãã«ã§ã®ã¢ã¯ã»ã¹æ¨©ãè¨å®å¯è½ã¨ããé常ã«ä¾¿å©ãªãã¼ã«ã§ãã ããããã®æ©è½ãæ¯ããè£å´ã§ã¯è¤éãªã¯ã¨ãªãçºè¡ãããMySQL ã«å¤å¤§ãªè² è·ãããã¦ãã¾ãããµã¤ãã¦ãºã®ã¯ã©ã¦ãã«ã¯æ°åãã©ãã¤ãã«ç»ã MySQL ãã¼ã¿ããããæ°åä¸ä»¶ãªã¼ãã¼ã®ãã¼ãã«ãè¤æ° JOIN ããã¯ã¨ãªãæ¯ç§ã®ããã«å®è¡ãããã¨ãããã¨ã³ã¸ãã¢éã滾ãç°å¢ã§ãã ç¾å¨ãµã¤ãã¦ãºã§ã¯æ§è½æ¹åã«åãå ¥ãã¦ãããåããã®æ¥åã«å¾äºãã¦ãã¾ããä¾ãã°2018å¹´
ã²ã¼ã å ã§ä½¿ç¨ãã¦ãã¡ã¢ãªãææ¡ããã®ã«å°ãã ã便å©ãªMemory Profilerã«ã¤ãã¦ã§ãã ã²ã¼ã å ã§ä½¿ç¨ãã¦ããã¡ã¢ãª å°å ¥æ¹æ³ 使ãæ¹ ã²ã¼ã ä¸ã®ã¡ã¢ãªãåå¾ãã ã¢ã»ããã®è¿½è·¡ 追è¨ï¼ãã¯ã¹ãã£ã®ä¸èº«ãç¥ãããå ´åï¼ é¢é£ ã²ã¼ã å ã§ä½¿ç¨ãã¦ããã¡ã¢ãª ã²ã¼ã å ã§ä½¿ç¨ãã¦ããã¡ã¢ãªã¯ãProfilerã®Memoryã®é ç®ã§ç¢ºèªããäºãåºæ¥ã¾ããããã§ã¯ãAssetsï¼ä½¿ç¨ä¸ã®ã¢ã»ããï¼ããNot Savedï¼å®è¡æã«çæãããã¢ã»ããï¼ããBuilding Resourcesï¼ã¨ã³ã¸ã³å ã«å«ã¾ããã¢ã»ããï¼ããScene Memoryï¼ã·ã¼ã³ã«å«ã¾ããã¢ã»ããï¼ãã¨ãã£ãé ç®ã§åå¥ããã¦ãã¾ãã ãããåç´ã«ãç´°ããäºã¯è¯ãããUnityãã¡ã¢ãªä¸è¶³ã§è½ã¡ããããä¸çªéãé ç®ãç¥ããããã¨ãã£ãå ´åã¯å¤ã åå¨ãã¾ãã ãããªæã«Memory Profilerã¯å²ã¨ç´è¦³çã«åã
"Nested Loop Joinããåãä¸ãã¦ç¡ãã®ã«ã¿ã¤ãã«ã大ããããªãã" ã¨ææãé ããã®ã§ãã¿ã¤ãã«ãä¿®æ£ãã¾ãããMerge Joinã¨Hash Joinã®ãã¨ã¯ã¾ãä»åº¦æ¸ããã¨æãã¾ãã ãJOINã¯é ããã¨ããè¨ããã¾ããç¹ã«RDBã使ãå§ãã¦éããªãå ã«ããããè¨èª¬ã«è§¦ããçµæãJOIN=æªãã¨ããèªèã§åºå®åããã¦ãã¾ã£ã¦ãã人ãå¤ãããã«æãã¦ãã¾ãã ãããã«ãJOINãå«ããããªSELECTæã¯ãå«ã¾ãªããã®ã«æ¯ã¹ã¦éãããªãå¾åããããã¨ã¯äºå®ã§ããã¾ããæ¬è³ªçã«åãåããããå 容ãè¤éã§ã対å¦ãããã¨ãé£ãããã®ãåå¨ãã¾ããããããRDBã®ä¸ã§ä¸ä½ã©ããããã¨ãèµ·ãã¦ããã®ããç¥ããããã«åºãã¦å¯¾å¦ããã°é«éåã§ãããã¨ãå°ãªããªãã¨èãã¦ãã¾ãã æ¬ç¨¿ã§ã¯ãJOINã®å é¨åä½ã解説ããä¸ã§ãWebãµã¼ãã¹ãä½ã£ã¦ããã¨ããåºã¦ããJOIN SQLãä¾é¡ã«
ããªãã®ãã¼ã¸èªã¿è¾¼ã¿é度ãé ããã¾ãããï¼ ãµã¤ãããªããªã表示ãããªãã®ã¯ã¦ã¼ã¶ã¼ã¨ãã¦è¦ãæã«é常ã«ã¹ãã¬ã¹ãã«ãçæ³ã®ãã¼ã¸ã®è¡¨ç¤ºæéã¯æä½ã§ã2ç§ä»¥å ãç®æãã¹ãã¯1ç§ä»¥å ã¨è¨ããã¦ããã gori.meã§ãé·ããã¨æ§ã ãªãã¼ã«ãé§ä½¿ãã¦ã¯èªã¿è¾¼ã¿é度æ¹åã«ããã¦åãçµãã§ãããå æ¥ãã¤ãã«GTMetrixã«ããã測å®å¤ãå®å®ãã¦1ç§å°ãåºããã¨ã«æåããã®ã§ãä»åã¯ãããå®ç¾ããããã«åãå®æ½ãã5ã¤ã®æ½çãã¾ã¨ãã¦ããï¼ãã¼ã¸ã®èªã¿è¾¼ã¿é度ã«æ©ãã§ãã人ã¯åèã«ã©ããï¼ gori.meã®GTMetrixã¹ã³ã¢ã¨èªã¿è¾¼ã¿é度 1ç§å°ãåºãæ¹æ³ã話ãåã«ããããæ¬å½ã«gori.meã¯èªã¿è¾¼ã¿é度1ç§å°ãªã®ãã¨ãããã¨ã«ã¤ãã¦ãå ã»ã©åå¾ããGTMetrixã®ã¹ã¯ãªã¼ã³ã·ã§ããã¨å ±ã«ç´¹ä»ãã¦ããã ã覧ã®éããèªã¿è¾¼ã¿é度ã¯1.4ç§ãGoogleã®ãPage Speed Grade
ããããã¤ã¨ã³ããªã ãã¨ããã®ããªããªã®ã§ãå¼ãç¶ãfujimotoã§ããå®è³ªä¸1ã¤ãã®ãããªæ°ããããã®ã¨ã³ããªã§ã¯ãPHPã3åããã(å°ãªãã¨ã2åãããã¯...)éããªãGree Fast Processorã¨ããã®ãå æä½ã£ã¦ã¿ãã®ã§ãç´¹ä»ã§ãã ãããããã¾ã¨ã Gree Fast Processorã¨ããã®ã使ã£ã¦ã¿ãã¨ãã·ã³ãã«ãªsymfonyã®ããã¸ã§ã¯ã(xav.ccã§è©¦ãã¾ãã)ã§ã2åå¼±ãçµæ§è¤éãªã¢ããªã±ã¼ã·ã§ã³ã ã¨7åãããéããªã£ãããã¾ããããã¤ãã®å¶ç´ãããã¾ãããããã©ã¼ãã³ã¹ã«é£¢ãã¦ããããã¯ã試ããã ããã ãã¡ãã¯ãªãããããéããªã£ã¦ããæãã®ã°ã©ã(ä¸çªä¸ãéããªã£ãçã®Requests per Secondã赤ãé常çã®Requests per Second): ããã¯ãããã«best caseãããæ°ããã¾ãããæ®éã«ãã£ã¦ã2åå¼±ãããã¯
以åãMySQLãé«éåãã10ã®æ¹æ³ã¨ããæ稿ã§ãEXPLAINã®è¦æ¹ã«ã¤ãã¦ã¯ããã解説ãããã¨æããã¨æ¸ãã¦ãã¾ã£ãã®ã§ãä»æ¥ã¯ãã®å ¬ç´ï¼ãæãããã¨æãã MySQLã®ãã¥ã¼ãã³ã°ã§æã大åãªã®ã¯ãã¯ã¨ãªã¨ã¹ãã¼ãã®æé©åã§ãããã¹ãã¼ãã®è¨è¨ã¯ä¸åº¦æ±ºãã¦ãã¾ãã¨ãã®ãã¼ãã«ãå©ç¨ããå ¨ã¦ã®ã¯ã¨ãªã«å½±é¿ãã¦ãã¾ããããªããªãå¤æ´ãããã¨ã¯åºæ¥ãªãããã¯ã¨ãªã¯ãã®ã¯ã¨ãªã ããæ¸ãç´ãã°è¯ãã®ã§å¤æ´ã®æ·å± ã¯ä½ããããã¦é ãã¯ã¨ãªããªãããã¨ã¯ãæ§è½ãå¤§å¹ ã«åä¸ãããããã®æãæå¹ãªæ段ã§ãããå¾ã£ã¦ãã¢ããªã±ã¼ã·ã§ã³ã®æ§è½ãåä¸ãããããªããã¾ãæåã«ã¯ã¨ãªã®ãã¥ã¼ãã³ã°ãæ¤è¨ããã¹ããªã®ã§ããã æé©åããã¹ãã¯ã¨ãªã¯ã¹ãã¼ã¯ã¨ãªãã°ãã¯ã¨ãªã¢ãã©ã¤ã¶ã§è¦ä»ããããããã§ã¯ãã®ãããªã¯ã¨ãªãè¦ã¤ãã£ãå ´åã«ã¯ã©ã®ããã«æé©åããã°ããã®ãï¼ãã®ããã«ã¯ã¾ãç¾å¨ã©ã®ããã«ã¯ã¨ãªãå®è¡ã
ã¡ãã£ã¨ãã£ããâãªã¿ã¤ãã«ãã¤ãã¦ãã¾ã£ãããä»æ¥ã¯ç¬æã¨åè¦ã§MySQLãé«éåããæ¹æ³ã10åç´¹ä»ããããMySQLãµã¼ãããã¥ã¼ãã³ã°ããã¨ããåæå°å ¥ããå ´åãªã©ã«åèã«ãã¦ãããããã 1. ãããã¡ãå¢ãããã¾ãã¯æ¸ãã ãã¥ã¼ãã³ã°ã®åºæ¬ä¸ã®åºæ¬ã§ããããé©åãªãããã¡ãµã¤ãºãè¨å®ãããã¨ã¯ããã©ã¼ãã³ã¹ãã¥ã¼ãã³ã°ã®è¦ã§ããã主ãªãããã¡ã¯æ¬¡ã®éãã innodb_buffer_pool_sizeã»ã»ã»InnoDBã ããå©ç¨ããå ´åã¯ç©ºãã¡ã¢ãªã®7ã8å²ç¨åº¦ãå²ãå½ã¦ãæãéè¦ãªãããã¡ã§ãããä½è«ã ããå®éã«ã¯ããã§å²ãå½ã¦ãå¤ã®5ã10%ããããå¤ãã«ã¡ã¢ãªã使ãã®ã§æ³¨æãå¿ è¦ã ã key_buffer_sizeã»ã»ã»MyISAMã ããå©ç¨ããå ´åã¯ã空ãã¡ã¢ãªã®3å²ç¨åº¦ãå²ãå½ã¦ãã¨ãããæ®ãã¯ãã¡ã¤ã«ã·ã¹ãã ã®ãã£ãã·ã¥ç¨ã«æ®ãã¦ãããã sort_buffer_
11æ25æ¥ããmobidec 2011ãã«ããã¦ã³ãããã¸ã¿ã«ã¨ã³ã¿ãã¤ã³ã¡ã³ãã®ã¹ã¿ã¸ãªITã»ã³ã¿ã¼é·ã§ããæ£å»¶å å¼æ°ã«ããã»ãã·ã§ã³ã大ãããSNSã²ã¼ã ããã©ã´ã³ã³ã¬ã¯ã·ã§ã³ããæ¯ããã³ããã®ã¯ã©ã¦ãæè¡ã®æ´»ç¨ããè¡ããã¾ããã ãã©ã´ã³ã³ã¬ã¯ã·ã§ã³ã¯ãGREEã§æä¾ããã¦ããæºå¸¯é»è©±åãã®ã«ã¼ãã²ã¼ã ã¿ã¤ãã®RPGããã¬ã¤ã¤ã¼ã¯ãã¨ãªã¢ãã¨ã«ããè¤æ°ã®ã¯ã¨ã¹ããã¯ãªã¢ãã¦ãããã¢ã³ã¹ã¿ã¼ã«ã¼ãããç§å®ããæã«å ¥ããããã«ããã©ã´ã³ã«ã¼ãããéãã¦ããã¾ããã¾ããã»ãã®ãã¬ã¤ã¤ã¼ã¨ããã«ãããã¨ã§ãç§å®ãå ¥æã§ããã¨ããSNSè¦ç´ ãåãå ¥ãããã¦ãã¾ããã2010å¹´9æã®ãµã¼ãã¹éå§å¾ãé 調ã«ãã¬ã¤ã¤ã¼æ°ã伸ã°ããç¾å¨ã§ã¯ç»é²äººæ°ã500ä¸äººãè¶ ãã¦ãã¾ãã ãµã¼ãã¹éå§å½åã¯ç¤¾å ã§ãµã¼ããæ§ç¯ããããã³ãã¨ã³ãã«6å°ã®ãµã¼ããããã¯ã¨ã³ãã«3å°ã®ãã¼ã¿ãã¼ã¹ãµã¼ããããã¦ãã¼ãã
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}