Actual branch TEA implementation

ready to test using BOINC with all possible settings (evaluator,
circuit/polynoms...)

Used config.xml:
<?xml version="1.0" ?>
<EACIRC>
    <NOTES>tea test</NOTES>
    <MAIN>
		<CIRCUIT_REPRESENTATION>1</CIRCUIT_REPRESENTATION>
        <PROJECT>100</PROJECT> <!-- estream -->
        <EVALUATOR>25</EVALUATOR>
        <EVALUATOR_PRECISION>10</EVALUATOR_PRECISION>
        <RECOMMENCE_COMPUTATION>0</RECOMMENCE_COMPUTATION>
        <LOAD_INITIAL_POPULATION>0</LOAD_INITIAL_POPULATION>
        <NUM_GENERATIONS>30000</NUM_GENERATIONS>
        <SAVE_STATE_FREQ>1000</SAVE_STATE_FREQ>
		<CIRCUIT_SIZE_INPUT>16</CIRCUIT_SIZE_INPUT>
		<CIRCUIT_SIZE_OUTPUT>1</CIRCUIT_SIZE_OUTPUT>
    </MAIN>
    <OUTPUTS>
        <GRAPH_FILES>1</GRAPH_FILES>
        <INTERMEDIATE_CIRCUITS>1</INTERMEDIATE_CIRCUITS>
        <ALLOW_PRUNNING>0</ALLOW_PRUNNING>
        <SAVE_TEST_VECTORS>0</SAVE_TEST_VECTORS>
    </OUTPUTS>
    <RANDOM>
        <USE_FIXED_SEED>0</USE_FIXED_SEED>
        <SEED>123456789</SEED>
        <BIAS_RNDGEN_FACTOR>95</BIAS_RNDGEN_FACTOR>
        <USE_NET_SHARE>0</USE_NET_SHARE>
        <QRNG_PATH>../qrng/;C:/RNG/;D:/RandomData/</QRNG_PATH>
        <QRNG_MAX_INDEX>192</QRNG_MAX_INDEX>
    </RANDOM>
    <CUDA>
        <ENABLED>0</ENABLED>
        <SOMETHING>something</SOMETHING>
    </CUDA>
    <GA>
        <EVOLUTION_OFF>0</EVOLUTION_OFF>
        <PROB_MUTATION>0.05</PROB_MUTATION>
        <MUTATE_FUNCTIONS>1</MUTATE_FUNCTIONS>
        <MUTATE_CONNECTORS>1</MUTATE_CONNECTORS>
        <PROB_CROSSING>0.5</PROB_CROSSING>
        <POPULATION_SIZE>20</POPULATION_SIZE>
        <REPLACEMENT_SIZE>13</REPLACEMENT_SIZE>
    </GA>
    <GATE_CIRCUIT>
		<MUTATE_FUNCTIONS>1</MUTATE_FUNCTIONS>
		<MUTATE_CONNECTORS>1</MUTATE_CONNECTORS>
		<NUM_LAYERS>5</NUM_LAYERS>
		<SIZE_LAYER>8</SIZE_LAYER>
		<NUM_CONNECTORS>4</NUM_CONNECTORS>
		<USE_MEMORY>0</USE_MEMORY>
		<SIZE_MEMORY>2</SIZE_MEMORY>
		<ALLOWED_FUNCTIONS>
			<FNC_NOP>1</FNC_NOP>
			<FNC_CONS>1</FNC_CONS>
			<FNC_AND>1</FNC_AND>
			<FNC_NAND>1</FNC_NAND>
			<FNC_OR>1</FNC_OR>
			<FNC_XOR>1</FNC_XOR>
			<FNC_NOR>1</FNC_NOR>
			<FNC_NOT>1</FNC_NOT>
			<FNC_SHIL>0</FNC_SHIL>
			<FNC_SHIR>0</FNC_SHIR>
			<FNC_ROTL>0</FNC_ROTL>
			<FNC_ROTR>0</FNC_ROTR>
			<FNC_EQ>0</FNC_EQ>
			<FNC_LT>0</FNC_LT>
			<FNC_GT>0</FNC_GT>
			<FNC_LEQ>0</FNC_LEQ>
			<FNC_GEQ>0</FNC_GEQ>
			<FNC_BSLC>1</FNC_BSLC>
			<FNC_READ>0</FNC_READ>
			<FNC_EXT>0</FNC_EXT>
		</ALLOWED_FUNCTIONS>
	</GATE_CIRCUIT>
	<POLYNOMIAL_CIRCUIT>
		<NUM_POLYNOMIALS>1</NUM_POLYNOMIALS>
		<MAX_TERMS>50</MAX_TERMS>
		<MUTATE_TERM_STRATEGY>1</MUTATE_TERM_STRATEGY>
		<TERM_COUNT_P>1.00</TERM_COUNT_P>
		<TERM_VAR_P>0.60</TERM_VAR_P>
		<ADD_TERM_P>0.05</ADD_TERM_P>
		<ADD_TERM_STRATEGY>0</ADD_TERM_STRATEGY>
		<RM_TERM_P>0.05</RM_TERM_P>
		<RM_TERM_STRATEGY>0</RM_TERM_STRATEGY>
		<CROSSOVER_RANDOMIZE_POLY>1</CROSSOVER_RANDOMIZE_POLY>
		<CROSSOVER_TERM_P>0.05</CROSSOVER_TERM_P>
	</POLYNOMIAL_CIRCUIT>
	<TEST_VECTORS>
        <INPUT_LENGTH>16</INPUT_LENGTH>
        <OUTPUT_LENGTH>2</OUTPUT_LENGTH>
        <SET_SIZE>1000</SET_SIZE>
        <SET_CHANGE_FREQ>200</SET_CHANGE_FREQ>
        <EVALUATE_BEFORE_TEST_VECTOR_CHANGE>0</EVALUATE_BEFORE_TEST_VECTOR_CHANGE>
        <EVALUATE_EVERY_STEP>0</EVALUATE_EVERY_STEP>
    </TEST_VECTORS>
    <ESTREAM>
        <USAGE_TYPE>101</USAGE_TYPE>
        <CIPHER_INIT_FREQ>0</CIPHER_INIT_FREQ> <!-- no need to reinit
tea -->
        <ALGORITHM_1>23</ALGORITHM_1> <!-- tea -->
        <ALGORITHM_2>99</ALGORITHM_2> <!-- qrng -->
        <BALLANCED_TEST_VECTORS>1</BALLANCED_TEST_VECTORS>
        <LIMIT_NUM_OF_ROUNDS>1</LIMIT_NUM_OF_ROUNDS>
        <ROUNDS_ALG_1>2</ROUNDS_ALG_1>
        <ROUNDS_ALG_2>0</ROUNDS_ALG_2>
        <PLAINTEXT_TYPE>3</PLAINTEXT_TYPE> <!-- stream of biased random
data -->
        <KEY_TYPE>2</KEY_TYPE>
        <IV_TYPE>0</IV_TYPE>
        <GENERATE_STREAM>0</GENERATE_STREAM>
        <STREAM_SIZE>1024</STREAM_SIZE>
    </ESTREAM>
</EACIRC>