libart icon indicating copy to clipboard operation
libart copied to clipboard

Node Header: MAX_PREFIX_LEN & uint8_t num_children

Open DeusProx opened this issue 7 years ago • 1 comments

Hello!

ATM I'm trying to get into the same paper you implemented here and noticed a problem:

  1. You defined the node header with a contant size of 16 Byte like the paper.
  2. The paper proposed to store a compressed path of 8 Bytes whilst your implementation defines it through MAX_PREFIX_LEN as 10 Bytes.
  3. Due to the necessity to store a compressed path of 10 Bytes & it's length (4 Bytes), you only have 2 Bytes left to store the node type & the amount of non null children (num_children).

Problem: I think num_children should be an uint16_t since at most we can store 256 children. Thus num_children should cover the integer range 0..256 (257 numbers) which don't fit into an uint8_t.

DeusProx avatar Jun 17 '18 12:06 DeusProx

This is related with https://github.com/armon/libart/issues/34

Lecrapouille avatar Nov 01 '18 16:11 Lecrapouille

House keeping: Related issue seems to be closed

DeusProx avatar Oct 16 '23 00:10 DeusProx