Searched refs:vector_sum (Results 1 – 1 of 1) sorted by relevance
183 int vector_sum = 0; // Sum up the vector elements as they are processed. in UpdateHistogram() local188 vector_sum += *it; in UpdateHistogram()195 vector_sum += (32768 - iat_factor_) << 15; // Add to vector sum. in UpdateHistogram()199 vector_sum -= 1 << 30; // Should be zero. Compensate if not. in UpdateHistogram()200 if (vector_sum != 0) { in UpdateHistogram()202 int flip_sign = vector_sum > 0 ? -1 : 1; in UpdateHistogram()204 while (it != iat_vector_.end() && abs(vector_sum) > 0) { in UpdateHistogram()206 int correction = flip_sign * std::min(abs(vector_sum), (*it) >> 4); in UpdateHistogram()208 vector_sum += correction; in UpdateHistogram()212 assert(vector_sum == 0); // Verify that the above is correct. in UpdateHistogram()