Changeset 2097 for trunk


Ignore:
Timestamp:
May 10, 2012, 12:15:52 PM (7 years ago)
Author:
ksherdy
Message:

Renamed all ends as follows.

Location:
trunk/symbol_table
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • trunk/symbol_table/demo_strms.py

    r2096 r2097  
    2525    groups = div2_group_strms.Groups()
    2626    groups.starts = markers.starts
    27     groups.ends = markers.ends
     27    groups.follows = markers.follows
    2828    div2_group_strms.Gen_lgth_groups(groups)
    2929
     
    3131        ('markers.spans', bitstream2string(markers.spans, lgth)),
    3232        ('markers.starts', bitstream2string(markers.starts, lgth)),
    33         ('markers.ends', bitstream2string(markers.ends, lgth)),
     33        ('markers.follows', bitstream2string(markers.follows, lgth)),
    3434        ('groups.starts', bitstream2string(groups.starts, lgth)),
    35         ('groups.ends', bitstream2string(groups.ends, lgth)),
    36         ('groups.ends_2', bitstream2string(groups.ends_2, lgth)),
    37         ('groups.ends_4', bitstream2string(groups.ends_4, lgth)),
    38         ('groups.ends_6', bitstream2string(groups.ends_6, lgth)),
    39         ('groups.ends_8', bitstream2string(groups.ends_8, lgth)),
    40         ('groups.ends_10', bitstream2string(groups.ends_10, lgth)),
    41         ('groups.ends_12', bitstream2string(groups.ends_12, lgth)),
    42         ('groups.ends_14', bitstream2string(groups.ends_14, lgth)),
    43         ('groups.ends_16', bitstream2string(groups.ends_16, lgth)),
    44         ('groups.ends_gte_17', bitstream2string(groups.ends_gte_17, lgth))])
     35        ('groups.follows', bitstream2string(groups.follows, lgth)),
     36        ('groups.follows_2', bitstream2string(groups.follows_2, lgth)),
     37        ('groups.follows_4', bitstream2string(groups.follows_4, lgth)),
     38        ('groups.follows_6', bitstream2string(groups.follows_6, lgth)),
     39        ('groups.follows_8', bitstream2string(groups.follows_8, lgth)),
     40        ('groups.follows_10', bitstream2string(groups.follows_10, lgth)),
     41        ('groups.follows_12', bitstream2string(groups.follows_12, lgth)),
     42        ('groups.follows_14', bitstream2string(groups.follows_14, lgth)),
     43        ('groups.follows_16', bitstream2string(groups.follows_16, lgth)),
     44        ('groups.follows_gte_17', bitstream2string(groups.follows_gte_17, lgth))])
    4545
    4646def Demo_logbase2(u8data, basis_bits):
     
    5454    groups = logbase2_group_strms.Groups()
    5555    groups.starts = markers.starts
    56     groups.ends = markers.ends
     56    groups.follows = markers.follows
    5757    logbase2_group_strms.Gen_lgth_groups(groups)
    5858
     
    6060        ('markers.spans', bitstream2string(markers.spans, lgth)),
    6161        ('markers.starts', bitstream2string(markers.starts, lgth)),
    62         ('markers.ends', bitstream2string(markers.ends, lgth)),
     62        ('markers.follows', bitstream2string(markers.follows, lgth)),
    6363        ('groups.starts', bitstream2string(groups.starts, lgth)),
    64         ('groups.ends', bitstream2string(groups.ends, lgth)),
    65         ('groups.ends_1', bitstream2string(groups.ends_1, lgth)),
    66         ('groups.ends_2', bitstream2string(groups.ends_2, lgth)),
    67         ('groups.ends_4', bitstream2string(groups.ends_4, lgth)),
    68         ('groups.ends_8', bitstream2string(groups.ends_8, lgth)),
    69         ('groups.ends_16', bitstream2string(groups.ends_16, lgth)),
    70         ('groups.ends_gte_17', bitstream2string(groups.ends_gte_17, lgth))])
     64        ('groups.follows', bitstream2string(groups.follows, lgth)),
     65        ('groups.follows_1', bitstream2string(groups.follows_1, lgth)),
     66        ('groups.follows_2', bitstream2string(groups.follows_2, lgth)),
     67        ('groups.follows_4', bitstream2string(groups.follows_4, lgth)),
     68        ('groups.follows_8', bitstream2string(groups.follows_8, lgth)),
     69        ('groups.follows_16', bitstream2string(groups.follows_16, lgth)),
     70        ('groups.follows_gte_17', bitstream2string(groups.follows_gte_17, lgth))])
    7171
    7272def Demo_div2_logbase2(u8data, basis_bits):
     
    8080    groups = div2_logbase2_group_strms.Groups()
    8181    groups.starts = markers.starts
    82     groups.ends = markers.ends
     82    groups.follows = markers.follows
    8383    div2_logbase2_group_strms.Gen_lgth_groups(groups)
    8484
     
    8686        ('markers.spans', bitstream2string(markers.spans, lgth)),
    8787        ('markers.starts', bitstream2string(markers.starts, lgth)),
    88         ('markers.ends', bitstream2string(markers.ends, lgth)),
     88        ('markers.follows', bitstream2string(markers.follows, lgth)),
    8989        ('groups.starts', bitstream2string(groups.starts, lgth)),
    90         ('groups.ends', bitstream2string(groups.ends, lgth)),
    91         ('groups.ends_2', bitstream2string(groups.ends_2, lgth)),
    92         ('groups.ends_4', bitstream2string(groups.ends_4, lgth)),
    93         ('groups.ends_6', bitstream2string(groups.ends_6, lgth)),
    94         ('groups.ends_8', bitstream2string(groups.ends_8, lgth)),
    95         ('groups.ends_16', bitstream2string(groups.ends_16, lgth)),
    96         ('groups.ends_gte_17', bitstream2string(groups.ends_gte_17, lgth))])
     90        ('groups.follows', bitstream2string(groups.follows, lgth)),
     91        ('groups.follows_2', bitstream2string(groups.follows_2, lgth)),
     92        ('groups.follows_4', bitstream2string(groups.follows_4, lgth)),
     93        ('groups.follows_6', bitstream2string(groups.follows_6, lgth)),
     94        ('groups.follows_8', bitstream2string(groups.follows_8, lgth)),
     95        ('groups.follows_16', bitstream2string(groups.follows_16, lgth)),
     96        ('groups.follows_gte_17', bitstream2string(groups.follows_gte_17, lgth))])
    9797
    9898if __name__ == "__main__":
  • trunk/symbol_table/div2_group_strms.py

    r2065 r2097  
    44class Groups():
    55        starts = 0
    6         ends = 0
    7         ends_2 = 0
    8         ends_4 = 0
    9         ends_6 = 0
    10         ends_8 = 0
    11         ends_10 = 0
    12         ends_12 = 0
    13         ends_14 = 0
    14         ends_16 = 0
    15         ends_gte_17 = 0
     6        follows = 0
     7        follows_2 = 0
     8        follows_4 = 0
     9        follows_6 = 0
     10        follows_8 = 0
     11        follows_10 = 0
     12        follows_12 = 0
     13        follows_14 = 0
     14        follows_16 = 0
     15        follows_gte_17 = 0
    1616
    1717def Gen_lgth_groups(groups):
    1818
    19         shift_or_ends = (groups.ends | pablo.Advance(groups.ends))
    20         ends = groups.ends
     19        shift_or_follows = (groups.follows | pablo.Advance(groups.follows))
     20        follows = groups.follows
    2121
    2222        # Group symbols of length 1 and length 2
    2323        cursor = pablo.Advance(pablo.Advance(groups.starts))
    24         groups.ends_2 = cursor & (shift_or_ends)
     24        groups.follows_2 = cursor & (shift_or_follows)
    2525
    2626        mask = pablo.Advance(groups.starts) | pablo.Advance(pablo.Advance(groups.starts))
    27         ends = ends &~ mask
     27        follows = follows &~ mask
    2828
    2929        # Group symbols of length 3 and length 4
    30         cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
    31         groups.ends_4 = cursor & (shift_or_ends)
     30        cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_follows))
     31        groups.follows_4 = cursor & (shift_or_follows)
    3232
    3333        mask = pablo.Advance(pablo.Advance(mask))
    34         ends = ends &~ mask
     34        follows = follows &~ mask
    3535
    3636        ## Group symbols of length 5 and length 6
    37         cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
    38         groups.ends_6 = cursor & (shift_or_ends)
     37        cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_follows))
     38        groups.follows_6 = cursor & (shift_or_follows)
    3939
    4040        mask = pablo.Advance(pablo.Advance(mask))
    41         ends = ends &~ mask
     41        follows = follows &~ mask
    4242
    4343        ## Group symbols of length 7 and length 8
    44         cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
    45         groups.ends_8 = cursor & (shift_or_ends)
     44        cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_follows))
     45        groups.follows_8 = cursor & (shift_or_follows)
    4646
    4747        mask = pablo.Advance(pablo.Advance(mask))
    48         ends = ends &~ mask
     48        follows = follows &~ mask
    4949
    5050        ## Group symbols of length 9 and length 10
    51         cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
    52         groups.ends_10 = cursor & (shift_or_ends)
     51        cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_follows))
     52        groups.follows_10 = cursor & (shift_or_follows)
    5353
    5454        mask = pablo.Advance(pablo.Advance(mask))
    55         ends = ends &~ mask
     55        follows = follows &~ mask
    5656
    5757        ## Group symbols of length 11 and length 12
    58         cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
    59         groups.ends_12 = cursor & (shift_or_ends)
     58        cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_follows))
     59        groups.follows_12 = cursor & (shift_or_follows)
    6060
    6161        mask = pablo.Advance(pablo.Advance(mask))
    62         ends = ends &~ mask
     62        follows = follows &~ mask
    6363
    6464        ## Group symbols of length 13 and length 14
    65         cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
    66         groups.ends_14 = cursor & (shift_or_ends)
     65        cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_follows))
     66        groups.follows_14 = cursor & (shift_or_follows)
    6767
    6868        mask = pablo.Advance(pablo.Advance(mask))
    69         ends = ends &~ mask
     69        follows = follows &~ mask
    7070
    7171        ## Group symbols of length 15 and length 16
    72         cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
    73         groups.ends_16 = cursor & (shift_or_ends)
     72        cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_follows))
     73        groups.follows_16 = cursor & (shift_or_follows)
    7474
    7575        mask = pablo.Advance(pablo.Advance(mask))
    76         ends = ends &~ mask
     76        follows = follows &~ mask
    7777
    7878        ## Group symbols of length greater than equal to 17
    79         groups.ends_gte_17 = ends
     79        groups.follows_gte_17 = follows
    8080
    8181def Main(groups):
  • trunk/symbol_table/group_strms_template.hpp

    r2054 r2097  
    1212static IDISA_ALWAYS_INLINE void identity_group_do_block(Markers & markers, Groups & groups) {
    1313        groups.starts = markers.starts;
    14         groups.ends = markers.ends;
     14        groups.follows = markers.follows;
    1515        // GENERATED
    1616        @group_strms_block_stmts
     
    1919static IDISA_ALWAYS_INLINE void identity_group_do_final_block(Markers & markers, Groups & groups, BitBlock & EOF_mask) {
    2020        groups.starts = markers.starts;
    21         groups.ends = markers.ends;
     21        groups.follows = markers.follows;
    2222        // GENERATED
    2323        @group_strms_final_block_stmts
  • trunk/symbol_table/id_group_strms.py

    r2065 r2097  
    44class Groups():
    55        starts = 0
    6         ends = 0
    7         ends_1 = 0
    8         ends_2 = 0
    9         ends_3 = 0
    10         ends_4 = 0
    11         ends_5 = 0
    12         ends_6 = 0
    13         ends_7 = 0
    14         ends_8 = 0
    15         ends_9 = 0
    16         ends_10 = 0
    17         ends_11 = 0
    18         ends_12 = 0
    19         ends_13 = 0
    20         ends_14 = 0
    21         ends_15 = 0
    22         ends_16 = 0
    23         ends_gte_17 = 0
     6        follows = 0
     7        follows_1 = 0
     8        follows_2 = 0
     9        follows_3 = 0
     10        follows_4 = 0
     11        follows_5 = 0
     12        follows_6 = 0
     13        follows_7 = 0
     14        follows_8 = 0
     15        follows_9 = 0
     16        follows_10 = 0
     17        follows_11 = 0
     18        follows_12 = 0
     19        follows_13 = 0
     20        follows_14 = 0
     21        follows_15 = 0
     22        follows_16 = 0
     23        follows_gte_17 = 0
    2424
    2525def Gen_lgth_groups(groups):
    2626
    2727        cursor = groups.starts
    28         temp = groups.ends
     28        temp = groups.follows
    2929
    3030        # Group symbols of length 1
    3131        cursor = pablo.Advance(cursor)
    32         groups.ends_1 = cursor & temp
    33         temp = temp & ~groups.ends_1
     32        groups.follows_1 = cursor & temp
     33        temp = temp & ~groups.follows_1
    3434
    3535        # Group symbols of length 2
    3636        cursor = pablo.Advance(cursor)
    37         groups.ends_2 = cursor & temp
    38         temp = temp & ~groups.ends_2
     37        groups.follows_2 = cursor & temp
     38        temp = temp & ~groups.follows_2
    3939
    4040        # Group symbols of length 3
    4141        cursor = pablo.Advance(cursor)
    42         groups.ends_3 = cursor & temp
    43         temp = temp & ~groups.ends_3
     42        groups.follows_3 = cursor & temp
     43        temp = temp & ~groups.follows_3
    4444
    4545        # Group symbols of length 4
    4646        cursor = pablo.Advance(cursor)
    47         groups.ends_4 = cursor & temp
    48         temp = temp & ~groups.ends_4
     47        groups.follows_4 = cursor & temp
     48        temp = temp & ~groups.follows_4
    4949
    5050        # Group symbols of length 5
    5151        cursor = pablo.Advance(cursor)
    52         groups.ends_5 = cursor & temp
    53         temp = temp & ~groups.ends_5
     52        groups.follows_5 = cursor & temp
     53        temp = temp & ~groups.follows_5
    5454
    5555        # Group symbols of length 6
    5656        cursor = pablo.Advance(cursor)
    57         groups.ends_6 = cursor & temp
    58         temp = temp & ~groups.ends_6
     57        groups.follows_6 = cursor & temp
     58        temp = temp & ~groups.follows_6
    5959
    6060        # Group symbols of length 7
    6161        cursor = pablo.Advance(cursor)
    62         groups.ends_7 = cursor & temp
    63         temp = temp & ~groups.ends_7
     62        groups.follows_7 = cursor & temp
     63        temp = temp & ~groups.follows_7
    6464
    6565        # Group symbols of length 8
    6666        cursor = pablo.Advance(cursor)
    67         groups.ends_8 = cursor & temp
    68         temp = temp & ~groups.ends_8
     67        groups.follows_8 = cursor & temp
     68        temp = temp & ~groups.follows_8
    6969
    7070        # Group symbols of length 9
    7171        cursor = pablo.Advance(cursor)
    72         groups.ends_9 = cursor & temp
    73         temp = temp & ~groups.ends_9
     72        groups.follows_9 = cursor & temp
     73        temp = temp & ~groups.follows_9
    7474
    7575        # Group symbols of length 10
    7676        cursor = pablo.Advance(cursor)
    77         groups.ends_10 = cursor & temp
    78         temp = temp & ~groups.ends_10
     77        groups.follows_10 = cursor & temp
     78        temp = temp & ~groups.follows_10
    7979
    8080        # Group symbols of length 11
    8181        cursor = pablo.Advance(cursor)
    82         groups.ends_11 = cursor & temp
    83         temp = temp & ~groups.ends_11
     82        groups.follows_11 = cursor & temp
     83        temp = temp & ~groups.follows_11
    8484
    8585        # Group symbols of length 12
    8686        cursor = pablo.Advance(cursor)
    87         groups.ends_12 = cursor & temp
    88         temp = temp & ~groups.ends_12
     87        groups.follows_12 = cursor & temp
     88        temp = temp & ~groups.follows_12
    8989
    9090        # Group symbols of length 13
    9191        cursor = pablo.Advance(cursor)
    92         groups.ends_13 = cursor & temp
    93         temp = temp & ~groups.ends_13
     92        groups.follows_13 = cursor & temp
     93        temp = temp & ~groups.follows_13
    9494
    9595        # Group symbols of length 14
    9696        cursor = pablo.Advance(cursor)
    97         groups.ends_14 = cursor & temp
    98         temp = temp & ~groups.ends_14
     97        groups.follows_14 = cursor & temp
     98        temp = temp & ~groups.follows_14
    9999
    100100        # Group symbols of length 15
    101101        cursor = pablo.Advance(cursor)
    102         groups.ends_15 = cursor & temp
    103         temp = temp & ~groups.ends_15
     102        groups.follows_15 = cursor & temp
     103        temp = temp & ~groups.follows_15
    104104
    105105        # Group symbols of length 16
    106106        cursor = pablo.Advance(cursor)
    107         groups.ends_16 = cursor & temp
    108         temp = temp & ~groups.ends_16
     107        groups.follows_16 = cursor & temp
     108        temp = temp & ~groups.follows_16
    109109
    110110        # Group symbols of length greater than 16
    111         groups.ends_gte_17 = temp
     111        groups.follows_gte_17 = temp
    112112
    113113def Main(groups):
  • trunk/symbol_table/logbase2_group_strms.py

    r2096 r2097  
    33class Groups():
    44        starts = 0
    5         ends = 0
    6         ends_1 = 0
    7         ends_2 = 0
    8         ends_4 = 0
    9         ends_8 = 0
    10         ends_16 = 0
    11         ends_gte_17 = 0
     5        follows = 0
     6        follows_1 = 0
     7        follows_2 = 0
     8        follows_4 = 0
     9        follows_8 = 0
     10        follows_16 = 0
     11        follows_gte_17 = 0
    1212
    1313def Gen_lgth_groups(groups):
    1414
    1515    starts = groups.starts
    16     remaining_ends = groups.ends
     16    remaining_follows = groups.follows
    1717
    1818    # Group symbols of length 1
    1919    starts_1 = pablo.Advance(starts)
    20     groups.ends_1 = starts_1 & remaining_ends
    21     remaining_ends = remaining_ends & ~groups.ends_1
     20    groups.follows_1 = starts_1 & remaining_follows
     21    remaining_follows = remaining_follows & ~groups.follows_1
    2222
    2323    # Group symbols of length 2
    2424    starts_2 = pablo.Advance(starts_1)
    25     groups.ends_2 = starts_2 & remaining_ends
    26     remaining_ends = remaining_ends & ~groups.ends_2
     25    groups.follows_2 = starts_2 & remaining_follows
     26    remaining_follows = remaining_follows & ~groups.follows_2
    2727
    2828    # Group symbols of length 3 to 4
     
    3131    starts_3_to_4 = pablo.Advance(pablo.Advance(temp))
    3232    #starts_3_to_4 = interpose32 (temp, temp32, 2)
    33     groups.ends_4 = starts_3_to_4 & remaining_ends
    34     remaining_ends = remaining_ends & ~groups.ends_4
     33    groups.follows_4 = starts_3_to_4 & remaining_follows
     34    remaining_follows = remaining_follows & ~groups.follows_4
    3535
    3636    # Group symbols of length 5 to 8
     
    3939    starts_5_to_8 = pablo.Advance(pablo.Advance(pablo.Advance(pablo.Advance(temp))))
    4040    #starts_5_to_8 = interpose32 (temp, temp32, 4)
    41     groups.ends_8 = starts_5_to_8 & remaining_ends
    42     remaining_ends = remaining_ends & ~groups.ends_8
     41    groups.follows_8 = starts_5_to_8 & remaining_follows
     42    remaining_follows = remaining_follows & ~groups.follows_8
    4343
    4444    # Group symbols of length 9 to 16
     
    4747    starts_9_16 = pablo.Advance(pablo.Advance(pablo.Advance(pablo.Advance(pablo.Advance(pablo.Advance(pablo.Advance(pablo.Advance(temp))))))))
    4848    #starts_9_16 = interpose32 (temp, temp32, 8)
    49     groups.ends_16 = starts_9_16 & remaining_ends
    50     remaining_ends = remaining_ends & ~groups.ends_16
     49    groups.follows_16 = starts_9_16 & remaining_follows
     50    remaining_follows = remaining_follows & ~groups.follows_16
    5151
    5252    # Group symbols of length 17 and longer
    53     groups.ends_gte_17 = remaining_ends
     53    groups.follows_gte_17 = remaining_follows
    5454
    5555def Main(groups):
  • trunk/symbol_table/main_template.cpp

    r2095 r2097  
    111111    BitBlock * starts = &lookback_starts[LOOKBACK_SIZE/BLOCK_SIZE];
    112112
    113     // ends_gte_17
    114     BitBlock aligned_ends_gte_17[SEGMENT_ALLOC_SIZE/8];
    115     BitBlock * lookback_ends_gte_17 = (BitBlock *) aligned_ends_gte_17;
    116     memset(lookback_ends_gte_17,0,LOOKBACK_SIZE/BLOCK_SIZE);
    117     BitBlock * ends_gte_17 = &lookback_ends_gte_17[LOOKBACK_SIZE/BLOCK_SIZE];
     113    // follows_gte_17
     114    BitBlock aligned_follows_gte_17[SEGMENT_ALLOC_SIZE/8];
     115    BitBlock * lookback_follows_gte_17 = (BitBlock *) aligned_follows_gte_17;
     116    memset(lookback_follows_gte_17,0,LOOKBACK_SIZE/BLOCK_SIZE);
     117    BitBlock * follows_gte_17 = &lookback_follows_gte_17[LOOKBACK_SIZE/BLOCK_SIZE];
    118118
    119119    // BitSteams - Without lookback
     
    146146        h1[blk] = hash[blk].h1;
    147147        starts[blk] = groups[blk].starts;
    148         ends_gte_17[blk] = groups[blk].ends_gte_17;
     148        follows_gte_17[blk] = groups[blk].follows_gte_17;
    149149    }
    150150
    151151    PERF_SEC_START(parser_timer);
    152     st.resolve(raw_buffer, groups, starts, ends_gte_17, h0, h1, SEGMENT_BLOCKS, gids);
     152    st.resolve(raw_buffer, groups, starts, follows_gte_17, h0, h1, SEGMENT_BLOCKS, gids);
    153153    PERF_SEC_END(parser_timer, SEGMENT_SIZE);
    154154
     
    160160
    161161    memmove(lookback_starts,&((uint8_t *)starts)[(SEGMENT_SIZE-LOOKBACK_SIZE)/8],LOOKBACK_SIZE/8);
    162     memmove(lookback_ends_gte_17,&((uint8_t *)ends_gte_17)[(SEGMENT_SIZE-LOOKBACK_SIZE)/8],LOOKBACK_SIZE/8);
     162    memmove(lookback_follows_gte_17,&((uint8_t *)follows_gte_17)[(SEGMENT_SIZE-LOOKBACK_SIZE)/8],LOOKBACK_SIZE/8);
    163163
    164164    //lookback_h0[0] = h0[SEGMENT_BLOCKS-1];
     
    218218        h1[blk] = hash[blk].h1;
    219219        starts[blk] = groups[blk].starts;
    220         ends_gte_17[blk] = groups[blk].ends_gte_17;
     220        follows_gte_17[blk] = groups[blk].follows_gte_17;
    221221    }
    222222
    223223    PERF_SEC_START(parser_timer);
    224     st.resolve(raw_buffer, groups, starts, ends_gte_17, h0, h1, segment_blocks, gids);
     224    st.resolve(raw_buffer, groups, starts, follows_gte_17, h0, h1, segment_blocks, gids);
    225225    PERF_SEC_END(parser_timer, chars_avail+1);
    226226
  • trunk/symbol_table/marker_strms.py

    r2043 r2097  
    44    spans = 0
    55    starts = 0
    6     ends = 0
     6    follows = 0
    77
    88# Calculate Symbol spans
     
    5151    markers.spans = (temp37 | temp40)
    5252
    53 # Determine Symbol starts, ends
     53# Determine Symbol starts, follows
    5454def Generate_markers(markers):
    5555    markers.starts = markers.spans &~ Advance(markers.spans)
    56     markers.ends = ~markers.spans & Advance(markers.spans)
     56    markers.follows = ~markers.spans & Advance(markers.spans)
    5757    #ScanThru(markers.starts, markers.spans)
    58     #markers.ends = ScanThru(markers.starts, markers.spans)
     58    #markers.follows = ScanThru(markers.starts, markers.spans)
    5959
    6060def Main(markers):
  • trunk/symbol_table/marker_strms_template.hpp

    r1960 r2097  
    99@marker_strms_stream_stmts
    1010
    11 static IDISA_ALWAYS_INLINE void markers_do_block(Basis_bits & basis_bits, Markers & markers) {//BitBlock & starts, BitBlock & ends) {
     11static IDISA_ALWAYS_INLINE void markers_do_block(Basis_bits & basis_bits, Markers & markers) {//BitBlock & starts, BitBlock & follows) {
    1212        // GENERATED
    1313        @marker_strms_block_stmts
    1414}
    1515
    16 static IDISA_ALWAYS_INLINE void markers_do_final_block(Basis_bits & basis_bits, Markers & markers, BitBlock & EOF_mask) { //  BitBlock & starts, BitBlock & ends, BitBlock & EOF_mask) {
     16static IDISA_ALWAYS_INLINE void markers_do_final_block(Basis_bits & basis_bits, Markers & markers, BitBlock & EOF_mask) { //  BitBlock & starts, BitBlock & follows, BitBlock & EOF_mask) {
    1717        // GENERATED
    1818        @marker_strms_final_block_stmts
  • trunk/symbol_table/src/symbol_table.hpp

    r2092 r2097  
    4444void do_block(uint32_t blk_offset,
    4545              HASH_TABLE & h_table,
    46               BitBlock ends,
     46              BitBlock follows,
    4747              uint8_t buffer [], const uint32_t lgth,
    4848              uint8_t h0 [], uint8_t h1 [], const uint32_t h_block_size,
     
    5252void do_block(uint32_t blk_offset,
    5353              HASH_TABLE & h_table,
    54               BitBlock starts [], BitBlock ends [],
     54              BitBlock starts [], BitBlock follows [],
    5555              uint8_t buffer [],
    5656              uint8_t h0 [], uint8_t h1 [], const uint32_t h_block_size,
     
    113113
    114114        // Groups & groups
    115         void resolve(uint8_t buffer [], Groups groups [],  BitBlock starts [], BitBlock ends_gte_17 [],
     115        void resolve(uint8_t buffer [], Groups groups [],  BitBlock starts [], BitBlock follows_gte_17 [],
    116116                                 BitBlock h0 [], BitBlock h1 [], uint32_t segment_blocks, GIDS & gids) {
    117117
     
    130130                        ///////////////////////////////////////////////////////////////////////////////
    131131                        #define BYTE_HASH_FIXED(GROUP_STRATEGY, HASH_STRATEGY, LGTH) \
    132                                 if(bitblock::any(groups.ends_##LGTH)) { \
     132                                if(bitblock::any(groups.follows_##LGTH)) { \
    133133                                        do_block<GIDS, GROUP_STRATEGY##_hash_table <LGTH, GROUP_STRATEGY, HASH_STRATEGY, ALLOCATOR> > \
    134134                                                (blk_offset, \
    135135                                                 hash_table_##LGTH, \
    136                                                  groups.ends_##LGTH, \
     136                                                 groups.follows_##LGTH, \
    137137                                                 buffer, LGTH, /* buffer, symbol length */ \
    138138                                                 buffer, buffer, BLOCK_SIZE, /* h0, h1, hash block size (bits) */ \
     
    144144                        ///////////////////////////////////////////////////////////////////////////////
    145145                        #define BYTE_HASH_VARIABLE(GROUP_STRATEGY, HASH_STRATEGY, LGTH) \
    146                                 if(bitblock::any(groups.ends_##LGTH)) { \
     146                                if(bitblock::any(groups.follows_##LGTH)) { \
    147147                                        do_block<GIDS, GROUP_STRATEGY##_hash_table <LGTH, GROUP_STRATEGY, HASH_STRATEGY, ALLOCATOR> > \
    148148                                                (blk_offset, \
    149149                                                 hash_table_##LGTH, \
    150150                                                 starts, \
    151                                                  &groups.ends_##LGTH, \
     151                                                 &groups.follows_##LGTH, \
    152152                                                 buffer, \
    153153                                                 buffer, buffer, BLOCK_SIZE, /* h0, h1, hash block size (bits) */ \
     
    160160                        ///////////////////////////////////////////////////////////////////////////////
    161161                        #define BIT_HASH_FIXED(GROUP_STRATEGY, HASH_STRATEGY, LGTH) \
    162                                 if(bitblock::any(groups.ends_##LGTH)) { \
     162                                if(bitblock::any(groups.follows_##LGTH)) { \
    163163                                        do_block<GIDS, GROUP_STRATEGY##_hash_table <LGTH, GROUP_STRATEGY, HASH_STRATEGY, ALLOCATOR> > \
    164164                                                (blk_offset, \
    165165                                                 hash_table_##LGTH, \
    166                                                  groups.ends_##LGTH, \
     166                                                 groups.follows_##LGTH, \
    167167                                                 buffer, LGTH, \
    168168                                                 (uint8_t *)h0, (uint8_t *)h1, (BLOCK_SIZE / 8), \
     
    174174                        ///////////////////////////////////////////////////////////////////////////////
    175175                        #define BIT_HASH_VARIABLE(GROUP_STRATEGY, HASH_STRATEGY, LGTH) \
    176                                 if(bitblock::any(groups.ends_##LGTH)) { \
     176                                if(bitblock::any(groups.follows_##LGTH)) { \
    177177                                        do_block<GIDS, GROUP_STRATEGY##_hash_table <LGTH, GROUP_STRATEGY, HASH_STRATEGY, ALLOCATOR> > \
    178178                                                (blk_offset, \
    179179                                                 hash_table_##LGTH, \
    180180                                                 starts, \
    181                                                  &groups.ends_##LGTH, \
     181                                                 &groups.follows_##LGTH, \
    182182                                                 buffer, \
    183183                                                 (uint8_t *)h0, (uint8_t *)h1, (BLOCK_SIZE / 8), /* h0, h1, hash block size (bits) */ \
     
    228228                        #undef BIT_HASH_VARIABLE
    229229
    230                         if(bitblock::any(groups.ends_gte_17)) {
     230                        if(bitblock::any(groups.follows_gte_17)) {
    231231                            do_block<GIDS, id_hash_table<0, id, bit, ALLOCATOR> >
    232232                                                (blk_offset,
    233233                                                 hash_table_gte_17,
    234                                                  starts, &groups.ends_gte_17,
     234                                                 starts, &groups.follows_gte_17,
    235235                                                 buffer,
    236236                                                 (uint8_t *)h0, (uint8_t *)h1, BLOCK_SIZE/8,
     
    295295void do_block(uint32_t blk_offset,
    296296                  HASH_TABLE & h_table,
    297                   BitBlock ends,
     297                  BitBlock follows,
    298298                  uint8_t buffer [], const uint32_t lgth,
    299299                  uint8_t h0 [], uint8_t h1 [], const uint32_t h_block_size,
     
    309309                uint32_t blk_count;
    310310
    311         ReverseScanner<BitBlock, scanword_t> rscanner(&ends);
     311        ReverseScanner<BitBlock, scanword_t> rscanner(&follows);
    312312
    313313        rscanner.scan_to_next();
     
    351351void do_block(uint32_t blk_offset,
    352352                          HASH_TABLE & h_table,
    353                           BitBlock starts [], BitBlock ends [],
     353                          BitBlock starts [], BitBlock follows [],
    354354                          uint8_t buffer [],
    355355                          uint8_t h0 [], uint8_t h1 [], const uint32_t h_block_size,
     
    367367        uint32_t blk_count = 0;
    368368
    369         ReverseScanner<BitBlock, scanword_t> ends_rscanner(ends);
     369        ReverseScanner<BitBlock, scanword_t> follows_rscanner(follows);
    370370        ReverseScanner<BitBlock, scanword_t> starts_rscanner(starts);
    371371
    372         ends_rscanner.scan_to_next();
    373         epos = ends_rscanner.get_pos();
    374 
    375         while(!ends_rscanner.is_done()) {
     372        follows_rscanner.scan_to_next();
     373        epos = follows_rscanner.get_pos();
     374
     375        while(!follows_rscanner.is_done()) {
    376376
    377377                starts_rscanner.move_to(epos);
     
    412412                #endif
    413413
    414                 ends_rscanner.scan_to_next();
    415                 epos = ends_rscanner.get_pos();
     414                follows_rscanner.scan_to_next();
     415                epos = follows_rscanner.get_pos();
    416416        }
    417417}
     
    423423void do_block(uint32_t blk_offset,
    424424                  HASH_TABLE & h_table,
    425                   BitBlock ends,
     425                  BitBlock follows,
    426426                  uint8_t buffer [], const uint32_t lgth,
    427427                  uint8_t h0 [], uint8_t h1 [], const uint32_t h_lgth, const uint32_t h_block_size,
     
    431431        int32_t spos;
    432432        int32_t epos;
    433         ForwardScanner<BitBlock, scanword_t> fscanner(&ends);
     433        ForwardScanner<BitBlock, scanword_t> fscanner(&follows);
    434434
    435435        fscanner.scan_to_next();
Note: See TracChangeset for help on using the changeset viewer.