随笔分类 -  源码阅读笔记

上一页 1 2 3 4 5 下一页
阅读源码的笔记
redis6.0.5之HyperLogLog阅读笔记1-基数估算前言翻译
摘要:/* The Redis HyperLogLog implementation is based on the following ideas: Redis的超对数实现是基于以下的想法: * * The use of a 64 bit hash function as proposed in [1] 阅读全文
posted @ 2021-03-11 17:28 子虚乌有 阅读(189) 评论(0) 推荐(0)
redis6.0.5之zset阅读笔记5--zset公共排序集相关API
摘要:*********************************************************************************************** 获取zset的元素个数 unsigned long zsetLength(const robj *zobj) 阅读全文
posted @ 2021-02-09 17:40 子虚乌有 阅读(196) 评论(0) 推荐(0)
redis6.0.5之zset阅读笔记4--压缩列表(ziplist)排序集相关API
摘要:*********************************************************************************************** 获取压缩链表中节点的数值 double zzlGetScore(unsigned char *sptr) { 阅读全文
posted @ 2021-02-08 17:27 子虚乌有 阅读(209) 评论(0) 推荐(0)
redis6.0.5之zset阅读笔记3--跳跃列表(zskiplist)之代码实现2-范围相关函数
摘要:*********************************************************************************************** /* Struct to hold a inclusive/exclusive range spec by 阅读全文
posted @ 2021-02-07 17:27 子虚乌有 阅读(105) 评论(0) 推荐(0)
redis6.0.5之zset阅读笔记3--跳跃列表(zskiplist)之代码实现1-增删改
摘要:*********************************************************************************************** typedef struct zskiplistNode { sds ele; 元素 double scor 阅读全文
posted @ 2021-02-05 16:05 子虚乌有 阅读(209) 评论(0) 推荐(0)
redis6.0.5之zset阅读笔记2--跳跃列表(zskiplist)之论文翻译4概率分析(又是无比艰难的一页,虽然跳表实现简单,但是分析不简单)
摘要:PROBABILISTIC ANALYSIS 概率分析 In addition to analyzing the expected performance of skip lists, we can also analyze the probabilistic performance of skip 阅读全文
posted @ 2021-02-02 20:50 子虚乌有 阅读(139) 评论(0) 推荐(0)
redis6.0.5之zset阅读笔记2--跳跃列表(zskiplist)之论文翻译3相关工作和总结 (这部分没有深入的挖掘相关文档,只是简单字面翻译)
摘要:ALTERNATIVE DATA STRUCTURES替代的数据结构 Balanced trees (e.g., AVL trees [Knu73] [Wir76]) and selfadjusting trees [ST85] can be used for the same problems a 阅读全文
posted @ 2021-02-02 11:00 子虚乌有 阅读(117) 评论(0) 推荐(0)
redis6.0.5之zset阅读笔记2--跳跃列表(zskiplist)之论文翻译2算法分析(这部分读的有点辛苦)
摘要:ANALYSIS OF SKIP LIST ALGORITHMS 跳跃链表的算法分析 The time required to execute the Search, Delete and Insert operations is dominated by the time required to 阅读全文
posted @ 2021-01-29 17:21 子虚乌有 阅读(100) 评论(0) 推荐(0)
redis6.0.5之zset阅读笔记2--跳跃列表(zskiplist)之论文翻译1综述及定义和算法
摘要:Skip Lists: A Probabilistic Alternative to Balanced Trees William Pugh 跳跃列表: 一种平衡树的概率代替方案--作者 William Pugh Skip lists are a data structure that can be 阅读全文
posted @ 2021-01-26 18:00 子虚乌有 阅读(175) 评论(0) 推荐(0)
redis6.0.5之zset阅读笔记1--跳跃列表(zskiplist)之初步介绍
摘要:/* ZSETs are ordered sets using two data structures to hold the same elements * in order to get O(log(N)) INSERT and REMOVE operations into a sorted * 阅读全文
posted @ 2021-01-25 17:29 子虚乌有 阅读(116) 评论(0) 推荐(0)
redis6.0.5之ziplist阅读笔记4--压缩列表(ziplist)之剩余函数
摘要:redis6.0.5之ziplist阅读笔记4--压缩列表(ziplist)之剩余函数 *********************************************************************** /* Merge ziplists 'first' and 'sec 阅读全文
posted @ 2021-01-22 16:24 子虚乌有 阅读(95) 评论(0) 推荐(0)
redis6.0.5之ziplist一段代码的理解--重现一个fix的bug
摘要:在阅读ziplist的函数unsigned char *__ziplistInsert(unsigned char *zl, unsigned char *p, unsigned char *s, unsigned int slen) 时候,其中有如下的代码段。。。 if (nextdiff == 阅读全文
posted @ 2021-01-21 17:06 子虚乌有 阅读(202) 评论(0) 推荐(0)
redis6.0.5之ziplist阅读笔记3--压缩列表(ziplist)之插入和删除
摘要:*********************************************************************** /* Given a pointer 'p' to the prevlen info that prefixes an entry, this * func 阅读全文
posted @ 2021-01-20 21:37 子虚乌有 阅读(178) 评论(0) 推荐(0)
redis6.0.5之Rax阅读笔记4-Iterator(迭代器)
摘要:1 /* Optional callback used for iterators and be notified on each rax node, 2 * including nodes not representing keys. If the callback returns true 3 阅读全文
posted @ 2021-01-18 21:36 子虚乌有 阅读(212) 评论(0) 推荐(0)
redis6.0.5之Rax阅读笔记3-删除和释放数据节点
摘要:************************************************************************************ /* Remove the specified item. Returns 1 if the item was found and 阅读全文
posted @ 2021-01-14 11:36 子虚乌有 阅读(207) 评论(0) 推荐(0)
redis6.0.5之基树rax理解测试
摘要:今天对这个基树单步跟踪理解了下,下面是用到的文件列表 ******************************************************* D:\mysourcecode\mytestcode\rax>tree /F 卷 新加卷 的文件夹 PATH 列表 卷序列号为 BA8 阅读全文
posted @ 2021-01-13 19:43 子虚乌有 阅读(278) 评论(0) 推荐(0)
redis6.0.5之Rax阅读笔记2-新增数据节点
摘要:*********************************************************************************** /* Allocate a new rax and return its pointer. On out of memory the 阅读全文
posted @ 2021-01-12 17:23 子虚乌有 阅读(230) 评论(1) 推荐(0)
redis6.0.5之Rax阅读笔记1-相关数据结构和部分辅助函数
摘要:/* Representation of a radix tree as implemented in this file, that contains * the strings "foo", "foobar" and "footer" after the insertion of each * 阅读全文
posted @ 2021-01-11 20:27 子虚乌有 阅读(225) 评论(0) 推荐(0)
redis6.0.5之redisObject阅读笔记--redis对象(redisObject)第二部分
摘要:************************************************************************************** #define sdsEncodedObject(objptr) (objptr->encoding == OBJ_ENCOD 阅读全文
posted @ 2020-12-30 11:39 子虚乌有 阅读(123) 评论(0) 推荐(0)
redis6.0.5之redisObject阅读笔记--redis对象(redisObject)第一部分
摘要:/* A redis object, that is a type able to hold a string / list / set */ redis对象,是用来保存 字符串,列表,集合的一种类型。 个人理解就是对这些不同的类型做一个统一的封装,这样对外面调用比较友好 /* The actual 阅读全文
posted @ 2020-12-18 17:18 子虚乌有 阅读(257) 评论(0) 推荐(0)

上一页 1 2 3 4 5 下一页