Changeset 2150 for trunk


Ignore:
Timestamp:
May 24, 2012, 5:20:26 PM (7 years ago)
Author:
ksherdy
Message:

Refactored buffer.hpp

Location:
trunk/symbol_table
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/symbol_table/main_template.cpp

    r2141 r2150  
    2424#include "../lib/bitblock.hpp"
    2525#include "../lib/bitblock_scan.hpp"
     26#include "../lib/buffer.hpp"
    2627#include "../lib/carryQ.hpp"
    2728#include "../lib/s2p.hpp"
    2829#include "../lib/perflib/perfsec.h"
    2930#include "transpose.hpp"
    30 #include "buffer.hpp"
     31
    3132#include "marker_strms.hpp"     // GENERATED HEADER
    3233#include "hash_strms.hpp"       // GENERATED HEADER
     
    7980    uint8_t * COPYBACK;
    8081    uint8_t * src_buffer;
    81 //    ALLOC_STATIC_ALIGNED_BYTE_BUFFER(COPYBACK, src_buffer);
    82         ATTRIBUTE_SIMD_ALIGN BitBlock aligned_base[BUFFER_SIZE];
    83         COPYBACK = (uint8_t *)aligned_base;
    84         memset(COPYBACK,0,COPYBACK_SIZE);
    85         src_buffer = &COPYBACK[COPYBACK_SIZE];
     82    ALLOC_STATIC_ALIGNED_BYTE_BUFFER_WITH_COPYBACK(COPYBACK, src_buffer);
     83//      ATTRIBUTE_SIMD_ALIGN BitBlock aligned_base[BUFFER_SIZE];
     84//      COPYBACK = (uint8_t *)aligned_base;
     85//      memset(COPYBACK,0,COPYBACK_SIZE);
     86//      src_buffer = &COPYBACK[COPYBACK_SIZE];
    8687
    8788    // hash 0
    8889    BitBlock * COPYBACK_h0;
    8990    BitBlock * h0;
    90     ALLOC_STATIC_ALIGNED_BITBLOCK_BUFFER(COPYBACK_h0, h0);
     91    ALLOC_STATIC_ALIGNED_BITBLOCK_BUFFER_WITH_COPYBACK(COPYBACK_h0, h0);
    9192
    9293    // hash 1
    9394    BitBlock * COPYBACK_h1;
    9495    BitBlock * h1;
    95     ALLOC_STATIC_ALIGNED_BITBLOCK_BUFFER(COPYBACK_h1, h1);
     96    ALLOC_STATIC_ALIGNED_BITBLOCK_BUFFER_WITH_COPYBACK(COPYBACK_h1, h1);
    9697
    9798    // starts
    9899    BitBlock * COPYBACK_starts;
    99100    BitBlock * starts;
    100     ALLOC_STATIC_ALIGNED_BITBLOCK_BUFFER(COPYBACK_starts, starts);
     101    ALLOC_STATIC_ALIGNED_BITBLOCK_BUFFER_WITH_COPYBACK(COPYBACK_starts, starts);
    101102
    102103    // follows_0 - Arbitrary length symbols
    103104    BitBlock * COPYBACK_follows_0;
    104105    BitBlock * follows_0;
    105     ALLOC_STATIC_ALIGNED_BITBLOCK_BUFFER(COPYBACK_follows_0, follows_0);
     106    ALLOC_STATIC_ALIGNED_BITBLOCK_BUFFER_WITH_COPYBACK(COPYBACK_follows_0, follows_0);
    106107
    107108    ///////////////////////////////////////////////////////////////////////////
  • trunk/symbol_table/src/Makefile

    r2141 r2150  
    2020# Perf Builds
    2121###########################################################################
    22 id: basis_bits.hpp buffer.hpp byte_pool.hpp hash_strms.hpp  hash_table.hpp ../lib/hash.hpp  group_strms.hpp  symbol_table.hpp  main.cpp  marker_strms.hpp symbol_table.hpp transpose.hpp
     22id: basis_bits.hpp ../lib/buffer.hpp byte_pool.hpp hash_strms.hpp  hash_table.hpp ../lib/hash.hpp  group_strms.hpp  symbol_table.hpp  main.cpp  marker_strms.hpp symbol_table.hpp transpose.hpp
    2323        $(CC) -o id main.cpp $(AFLAGS) -DID_STRATEGY -DBUFFER_PROFILING  #-DID_SYMBOL_TABLE_TEMPLATE_HPP_DEBUG #-DHASH_TABLE_HPP_DEBUG
    2424
    25 div2: basis_bits.hpp buffer.hpp byte_pool.hpp hash_strms.hpp  hash_table.hpp ../lib/hash.hpp  group_strms.hpp  symbol_table.hpp  main.cpp  marker_strms.hpp symbol_table.hpp transpose.hpp
     25div2: basis_bits.hpp ../lib/buffer.hpp byte_pool.hpp hash_strms.hpp  hash_table.hpp ../lib/hash.hpp  group_strms.hpp  symbol_table.hpp  main.cpp  marker_strms.hpp symbol_table.hpp transpose.hpp
    2626        $(CC) -o div2 main.cpp $(AFLAGS) -DDIV2_STRATEGY -DBUFFER_PROFILING  #-DHASH_TABLE_HPP_DEBUG #-DID_SYMBOL_TABLE_TEMPLATE_HPP_DEBUG
    2727
    28 logbase2: basis_bits.hpp buffer.hpp byte_pool.hpp hash_strms.hpp  hash_table.hpp ../lib/hash.hpp  group_strms.hpp  symbol_table.hpp  main.cpp  marker_strms.hpp symbol_table.hpp transpose.hpp
     28logbase2: basis_bits.hpp ../lib/buffer.hpp byte_pool.hpp hash_strms.hpp  hash_table.hpp ../lib/hash.hpp  group_strms.hpp  symbol_table.hpp  main.cpp  marker_strms.hpp symbol_table.hpp transpose.hpp
    2929        $(CC) -o logbase2 main.cpp $(AFLAGS) -DLOGBASE2_STRATEGY -DBUFFER_PROFILING  #-DID_SYMBOL_TABLE_TEMPLATE_HPP_DEBUG  #-DHASH_TABLE_HPP_DEBUG
    3030
    31 div2_logbase2: basis_bits.hpp buffer.hpp byte_pool.hpp hash_strms.hpp  hash_table.hpp ../lib/hash.hpp  group_strms.hpp  symbol_table.hpp  main.cpp  marker_strms.hpp symbol_table.hpp transpose.hpp
     31div2_logbase2: basis_bits.hpp ../lib/buffer.hpp byte_pool.hpp hash_strms.hpp  hash_table.hpp ../lib/hash.hpp  group_strms.hpp  symbol_table.hpp  main.cpp  marker_strms.hpp symbol_table.hpp transpose.hpp
    3232        $(CC) -o div2_logbase2 main.cpp $(AFLAGS) -DDIV2_LOGBASE2_STRATEGY -DBUFFER_PROFILING  #-DID_SYMBOL_TABLE_TEMPLATE_HPP_DEBUG  #-DHASH_TABLE_HPP_DEBUG
    3333
    34 bit_byte: basis_bits.hpp buffer.hpp byte_pool.hpp hash_strms.hpp  hash_table.hpp ../lib/hash.hpp  group_strms.hpp  symbol_table.hpp  main.cpp  marker_strms.hpp symbol_table.hpp transpose.hpp
     34bit_byte: basis_bits.hpp ../lib/buffer.hpp byte_pool.hpp hash_strms.hpp  hash_table.hpp ../lib/hash.hpp  group_strms.hpp  symbol_table.hpp  main.cpp  marker_strms.hpp symbol_table.hpp transpose.hpp
    3535        $(CC) -o bit_byte main.cpp $(AFLAGS) -DBIT_BYTE_STRATEGY -DBUFFER_PROFILING  #-DID_SYMBOL_TABLE_TEMPLATE_HPP_DEBUG  #-DHASH_TABLE_HPP_DEBUG
    3636
  • trunk/symbol_table/src/symbol_table.hpp

    r2141 r2150  
    2525
    2626#include "strategy_types.hpp"
    27 #include "buffer.hpp"
    2827#include "gid.hpp"
    2928#include "hash_table.hpp"
     29#include "../lib/buffer.hpp"
    3030#include "../lib/bitblock_iterator.hpp"
    3131#include "../lib/bitblock_scan.hpp"
Note: See TracChangeset for help on using the changeset viewer.