mysql源碼是什么語言

mysql的內存管理龐大而先進,這在mem0pool.c文件的開頭注釋中都有說明,粗略的可以分成四部分,包含9大塊:

mysql源碼是什么語言

九大塊:

buffer pool,  parsed andoptimized SQL statements,  data dictionarycache,  log buffer,  locks for eachtransaction,  hash table forthe adaptive index,  state andbuffers for each SQL query currently being executed,  Session foreach user, and  stack for eachOS thread.

9大塊通過4部分進行管理

A solution tothe memory management:  1. the bufferpool size is set separately;  2. log buffersize is set separately;  3. the commonpool size for all the other entries, except 8, is set separately.

也就是緩沖池,redo日志緩沖,普通池和8(用戶session信息,可看做一部分)

redo日志緩沖由redo部分單獨管理,bufferpool也就是緩沖池是一個復雜的部分,內容很多,普通池上面說了,除了8,和1,2.其余的都歸它管。
mysql是用C++開發的。
MySQL的官方網站http://www.mysql.com/上有源碼下載,是C++的

? 版權聲明
THE END
喜歡就支持一下吧
點贊6 分享