arnaucube
arnaucube/davinci-paperPublic Self-hosted repository
davinci-paper/v2/figures/blob-layout.drawio
v2/figures/blob-layout.drawioRaw
1<mxfile host="drawio"><diagram name="blob-layout" id="blob-layout"><mxGraphModel dx="1200" dy="800" grid="0" gridSize="10" guides="1" tooltips="1" connect="1" arrows="1" fold="1" page="0" pageScale="1" pageWidth="1100" pageHeight="850" math="0" shadow="0"><root><mxCell id="0"/><mxCell id="1" parent="0"/><mxCell id="c3" value="" style="rounded=0;whiteSpace=wrap;html=1;fontSize=11;fillColor=none;strokeColor=#000000;fontFamily=Courier New;verticalAlign=top;align=center;spacingTop=4;spacingLeft=6;fontStyle=1;" vertex="1" parent="1"><mxGeometry x="0" y="0" width="820" height="520" as="geometry"/></mxCell><mxCell id="c4" value="&lt;b&gt;cells&lt;/b&gt; (32-byte big-endian elements of the BLS12-381 scalar field), in order:" style="text;html=1;whiteSpace=wrap;fontSize=13;fontFamily=Courier New;align=left;verticalAlign=middle;fontColor=#000000;" vertex="1" parent="1"><mxGeometry x="14" y="8" width="790" height="24" as="geometry"/></mxCell><mxCell id="c5" value="header&lt;br&gt;n&lt;sub&gt;up&lt;/sub&gt; + 2&lt;sup&gt;64&lt;/sup&gt;&amp;middot;n&lt;sub&gt;id&lt;/sub&gt;" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#f5f5f5;strokeColor=#666666;fontFamily=Courier New;align=center;verticalAlign=middle;" vertex="1" parent="1"><mxGeometry x="16" y="38" width="110" height="52" as="geometry"/></mxCell><mxCell id="c6" value="n&lt;sub&gt;id&lt;/sub&gt; vote IDs, then n&lt;sub&gt;up&lt;/sub&gt; slots,&lt;br&gt;4 per cell: &amp;lceil;(n&lt;sub&gt;id&lt;/sub&gt;+n&lt;sub&gt;up&lt;/sub&gt;)/4&amp;rceil; cells" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#dae8fc;strokeColor=#6c8ebf;fontFamily=Courier New;align=center;verticalAlign=middle;" vertex="1" parent="1"><mxGeometry x="126" y="38" width="300" height="52" as="geometry"/></mxCell><mxCell id="c7" value="ballot of slot 1:&lt;br&gt;2&amp;middot;n&lt;sub&gt;f&lt;/sub&gt; point cells" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#ffe6cc;strokeColor=#d79b00;fontFamily=Courier New;align=center;verticalAlign=middle;" vertex="1" parent="1"><mxGeometry x="426" y="38" width="190" height="52" as="geometry"/></mxCell><mxCell id="c8" value="ballot of slot 2:&lt;br&gt;2&amp;middot;n&lt;sub&gt;f&lt;/sub&gt; point cells" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#ffe6cc;strokeColor=#d79b00;fontFamily=Courier New;align=center;verticalAlign=middle;" vertex="1" parent="1"><mxGeometry x="616" y="38" width="190" height="52" as="geometry"/></mxCell><mxCell id="c9" value="&amp;hellip;" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#ffffff;strokeColor=#000000;fontFamily=Courier New;align=center;verticalAlign=middle;" vertex="1" parent="1"><mxGeometry x="16" y="102" width="60" height="52" as="geometry"/></mxCell><mxCell id="c10" value="ballot of slot n&lt;sub&gt;up&lt;/sub&gt;:&lt;br&gt;2&amp;middot;n&lt;sub&gt;f&lt;/sub&gt; point cells" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#ffe6cc;strokeColor=#d79b00;fontFamily=Courier New;align=center;verticalAlign=middle;" vertex="1" parent="1"><mxGeometry x="76" y="102" width="220" height="52" as="geometry"/></mxCell><mxCell id="c11" value="zero cells up to&lt;br&gt;4096 &amp;middot; nBlobs" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#ffffff;strokeColor=#000000;fontFamily=Courier New;align=center;verticalAlign=middle;dashed=1;" vertex="1" parent="1"><mxGeometry x="296" y="102" width="230" height="52" as="geometry"/></mxCell><mxCell id="c12" value="split into blobs of 4096 cells: T = 1 + &amp;lceil;(n&lt;sub&gt;id&lt;/sub&gt;+n&lt;sub&gt;up&lt;/sub&gt;)/4&amp;rceil; + 2&amp;middot;n&lt;sub&gt;f&lt;/sub&gt;&amp;middot;n&lt;sub&gt;up&lt;/sub&gt; cells in total, nBlobs = &amp;lceil;T / 4096&amp;rceil; &amp;le; 32" style="text;html=1;whiteSpace=wrap;fontSize=12;fontFamily=Courier New;align=left;verticalAlign=middle;fontColor=#333333;" vertex="1" parent="1"><mxGeometry x="16" y="160" width="790" height="40" as="geometry"/></mxCell><mxCell id="c13" value="&lt;b&gt;packed cell&lt;/b&gt; = a&amp;middot;2&lt;sup&gt;189&lt;/sup&gt; + b&amp;middot;2&lt;sup&gt;126&lt;/sup&gt; + c&amp;middot;2&lt;sup&gt;63&lt;/sup&gt; + d" style="text;html=1;whiteSpace=wrap;fontSize=13;fontFamily=Courier New;align=left;verticalAlign=middle;fontColor=#000000;" vertex="1" parent="1"><mxGeometry x="16" y="204" width="480" height="24" as="geometry"/></mxCell><mxCell id="c14" value="0" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#ffffff;strokeColor=#000000;fontFamily=Courier New;align=center;verticalAlign=middle;" vertex="1" parent="1"><mxGeometry x="16" y="230" width="36" height="34" as="geometry"/></mxCell><mxCell id="c15" value="a (63 bits)" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#dae8fc;strokeColor=#6c8ebf;fontFamily=Courier New;align=center;verticalAlign=middle;" vertex="1" parent="1"><mxGeometry x="52" y="230" width="110" height="34" as="geometry"/></mxCell><mxCell id="c16" value="b (63 bits)" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#dae8fc;strokeColor=#6c8ebf;fontFamily=Courier New;align=center;verticalAlign=middle;" vertex="1" parent="1"><mxGeometry x="162" y="230" width="110" height="34" as="geometry"/></mxCell><mxCell id="c17" value="c (63 bits)" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#dae8fc;strokeColor=#6c8ebf;fontFamily=Courier New;align=center;verticalAlign=middle;" vertex="1" parent="1"><mxGeometry x="272" y="230" width="110" height="34" as="geometry"/></mxCell><mxCell id="c18" value="d (63 bits)" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#dae8fc;strokeColor=#6c8ebf;fontFamily=Courier New;align=center;verticalAlign=middle;" vertex="1" parent="1"><mxGeometry x="382" y="230" width="110" height="34" as="geometry"/></mxCell><mxCell id="c19" value="vote IDs enter without their top bit (they lie in [2&lt;sup&gt;63&lt;/sup&gt;, 2&lt;sup&gt;64&lt;/sup&gt;)); slots are already below 2&lt;sup&gt;63&lt;/sup&gt;" style="text;html=1;whiteSpace=wrap;fontSize=12;fontFamily=Courier New;align=left;verticalAlign=middle;fontColor=#333333;" vertex="1" parent="1"><mxGeometry x="16" y="266" width="480" height="40" as="geometry"/></mxCell><mxCell id="c20" value="&lt;b&gt;point cell&lt;/b&gt;: (x, y) &amp;rarr; y + 2&lt;sup&gt;254&lt;/sup&gt;&amp;middot;(x mod 2)" style="text;html=1;whiteSpace=wrap;fontSize=13;fontFamily=Courier New;align=left;verticalAlign=middle;fontColor=#000000;" vertex="1" parent="1"><mxGeometry x="16" y="320" width="480" height="24" as="geometry"/></mxCell><mxCell id="c21" value="0" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#ffffff;strokeColor=#000000;fontFamily=Courier New;align=center;verticalAlign=middle;" vertex="1" parent="1"><mxGeometry x="16" y="346" width="36" height="34" as="geometry"/></mxCell><mxCell id="c22" value="x mod 2" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#ffe6cc;strokeColor=#d79b00;fontFamily=Courier New;align=center;verticalAlign=middle;" vertex="1" parent="1"><mxGeometry x="52" y="346" width="90" height="34" as="geometry"/></mxCell><mxCell id="c23" value="y (254 bits, BN254 field element)" style="rounded=0;whiteSpace=wrap;html=1;fontSize=12;fillColor=#ffe6cc;strokeColor=#d79b00;fontFamily=Courier New;align=center;verticalAlign=middle;" vertex="1" parent="1"><mxGeometry x="142" y="346" width="350" height="34" as="geometry"/></mxCell><mxCell id="c24" value="the identity (0, 1) encodes as 1; p&lt;sub&gt;BN254&lt;/sub&gt; + 2&lt;sup&gt;254&lt;/sup&gt; &amp;lt; q&lt;sub&gt;BLS&lt;/sub&gt;, so every cell is a field element" style="text;html=1;whiteSpace=wrap;fontSize=12;fontFamily=Courier New;align=left;verticalAlign=middle;fontColor=#333333;" vertex="1" parent="1"><mxGeometry x="16" y="382" width="480" height="40" as="geometry"/></mxCell><mxCell id="c25" value="&lt;b&gt;binding to the commitments&lt;/b&gt;&lt;div style='text-align:left;font-size:12px;line-height:1.45;margin-top:4px'&gt;for each blob b with commitment com&lt;sub&gt;b&lt;/sub&gt;:&lt;br&gt;z&lt;sub&gt;b&lt;/sub&gt; = H(processID || stateRoot&lt;sup&gt;old&lt;/sup&gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;|| com&lt;sub&gt;b&lt;/sub&gt;) mod q&lt;sub&gt;BLS&lt;/sub&gt;&lt;br&gt;y&lt;sub&gt;b&lt;/sub&gt; = p&lt;sub&gt;b&lt;/sub&gt;(z&lt;sub&gt;b&lt;/sub&gt;), computed in the program&lt;br&gt;blobsDigest = H(com&lt;sub&gt;1&lt;/sub&gt; || y&lt;sub&gt;1&lt;/sub&gt; || &amp;hellip;)&lt;br&gt;&lt;br&gt;the registry opens each (com&lt;sub&gt;b&lt;/sub&gt;, z&lt;sub&gt;b&lt;/sub&gt;, y&lt;sub&gt;b&lt;/sub&gt;)&lt;br&gt;with the point-evaluation precompile&lt;br&gt;against the blob's versioned hash&lt;/div&gt;" style="rounded=0;whiteSpace=wrap;html=1;fontSize=13;fillColor=#dae8fc;strokeColor=#6c8ebf;fontFamily=Courier New;align=center;verticalAlign=top;spacingTop=8;spacingLeft=8;" vertex="1" parent="1"><mxGeometry x="512" y="204" width="292" height="222" as="geometry"/></mxCell><mxCell id="c26" value="Slots are listed once, in increasing order, whether they hold a new vote, an overwrite, or a silent refresh (n&lt;sub&gt;id&lt;/sub&gt; = n, n&lt;sub&gt;up&lt;/sub&gt; = n + |R|). The results accumulator is not published; observers recompute it from the old and new ballots of the listed slots." style="text;html=1;whiteSpace=wrap;fontSize=12;fontFamily=Courier New;align=left;verticalAlign=middle;fontColor=#333333;" vertex="1" parent="1"><mxGeometry x="16" y="440" width="790" height="70" as="geometry"/></mxCell></root></mxGraphModel></diagram></mxfile>