MCPcopy Create free account
hub / github.com/SimHacker/micropolis / n_vanneal8

Method n_vanneal8

MicropolisCore/src/CellEngine/src/cellengine.cpp:5162–5194  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5160
5161
5162void CellEngine::n_vanneal8()
5163{
5164 long sum0;
5165 long sum1;
5166 long sum2;
5167 long sum3;
5168 long sum4;
5169 long sum5;
5170 long sum6;
5171 long sum7;
5172
5173 if (total < hubba) {
5174 inflation = 1;
5175 } else if (total == hubba) {
5176 inflation = 0;
5177 } else {
5178 inflation = -1;
5179 } // if
5180
5181 total = 0;
5182
5183#define VANNEAL8 ( \
5184 ((((sum0 = inflation + SUM9REG(1)) > 5) || (sum0 == 4)) ? (total++, 1) : 0) | \
5185 ((((sum1 = inflation + (SUM9REG(2) >> 1)) > 5) || (sum1 == 4)) ? (total++, 2) : 0) | \
5186 ((((sum2 = inflation + (SUM9REG(4) >> 2)) > 5) || (sum2 == 4)) ? (total++, 4) : 0) | \
5187 ((((sum3 = inflation + (SUM9REG(8) >> 3)) > 5) || (sum3 == 4)) ? (total++, 8) : 0) | \
5188 ((((sum4 = inflation + (SUM9REG(16) >> 4)) > 5) || (sum4 == 4)) ? (total++, 16) : 0) | \
5189 ((((sum5 = inflation + (SUM9REG(32) >> 5)) > 5) || (sum5 == 4)) ? (total++, 32) : 0) | \
5190 ((((sum6 = inflation + (SUM9REG(64) >> 6)) > 5) || (sum6 == 4)) ? (total++, 64) : 0) | \
5191 ((((sum7 = inflation + (SUM9REG(128) >> 7)) > 5) || (sum7 == 4)) ? (total++, 128) : 0))
5192
5193 CAM_MASKED_REG_LOOP(VANNEAL8)
5194}
5195
5196#if 0
5197

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected