Lines Matching full:price
176 UInt32 price; member
773 UInt32 price = 0; in LitEnc_GetPrice() local
779 price += GET_PRICEa(probs[sym], bit); in LitEnc_GetPrice()
782 return price; in LitEnc_GetPrice()
788 UInt32 price = 0; in LitEnc_Matched_GetPrice() local
794 price += GET_PRICEa(probs[offs + (matchByte & offs) + (sym >> 8)], (sym >> 7) & 1); in LitEnc_Matched_GetPrice()
799 return price; in LitEnc_Matched_GetPrice()
871 UInt32 price = startPrice; in SetPrices_3() local
873 price += GET_PRICEa(probs[1 ], (i >> 2)); in SetPrices_3()
874 price += GET_PRICEa(probs[2 + (i >> 2)], (i >> 1) & 1); in SetPrices_3()
876 prices[i ] = price + GET_PRICEa_0(prob); in SetPrices_3()
877 prices[i + 1] = price + GET_PRICEa_1(prob); in SetPrices_3()
941 // UInt32 price = a + RcTree_GetPrice(probs, kLenNumHighBits - 1, sym, ProbPrices); in LenPriceEnc_UpdateTables()
943 UInt32 price = b; in LenPriceEnc_UpdateTables() local
948 price += GET_PRICEa(probs[sym], bit); in LenPriceEnc_UpdateTables()
954 prices[(size_t)i * 2 ] = price + GET_PRICEa_0(prob); in LenPriceEnc_UpdateTables()
955 prices[(size_t)i * 2 + 1] = price + GET_PRICEa_1(prob); in LenPriceEnc_UpdateTables()
1043 UInt32 price; in GetPrice_PureRep() local
1047 price = GET_PRICE_0(prob); in GetPrice_PureRep()
1048 price += GET_PRICE_1(p->isRep0Long[state][posState]); in GetPrice_PureRep()
1052 price = GET_PRICE_1(prob); in GetPrice_PureRep()
1055 price += GET_PRICE_0(prob); in GetPrice_PureRep()
1058 price += GET_PRICE_1(prob); in GetPrice_PureRep()
1059 price += GET_PRICE(p->isRepG2[state], repIndex - 2); in GetPrice_PureRep()
1062 return price; in GetPrice_PureRep()
1209 p->opt[1].price = GET_PRICE_0(p->isMatch[p->state][posState]) + in GetOptimum()
1224 if (shortRepPrice < p->opt[1].price) in GetOptimum()
1226 p->opt[1].price = shortRepPrice; in GetOptimum()
1248 UInt32 price; in GetOptimum() local
1251 price = repMatchPrice + GetPrice_PureRep(p, i, p->state, posState); in GetOptimum()
1254 UInt32 price2 = price + GET_PRICE_LEN(&p->repLenEnc, posState, repLen); in GetOptimum()
1256 if (price2 < opt->price) in GetOptimum()
1258 opt->price = price2; in GetOptimum()
1286 UInt32 price = normalMatchPrice + GET_PRICE_LEN(&p->lenEnc, posState, len); in GetOptimum() local
1290 price += p->distancesPrices[lenToPosState][dist & (kNumFullDistances - 1)]; in GetOptimum()
1295 price += p->alignPrices[dist & kAlignMask]; in GetOptimum()
1296 price += p->posSlotPrices[lenToPosState][slot]; in GetOptimum()
1301 if (price < opt->price) in GetOptimum()
1303 opt->price = price; in GetOptimum()
1328 printf("\nprice[%4X] = %u", position - cur + i, p->opt[i].price); in GetOptimum()
1355 UInt32 price = p->opt[cur].price; in GetOptimum() local
1359 UInt32 price2 = p->opt[j].price; in GetOptimum()
1360 if (price >= price2) in GetOptimum()
1362 price = price2; in GetOptimum()
1392 if (curOpt->price >= kInfinityPrice) in GetOptimum()
1480 The order of Price checks: in GetOptimum()
1489 UInt32 curPrice = curOpt->price; in GetOptimum()
1498 // here we can allow skip_items in p->opt, if we don't check (nextOpt->price < kInfinityPrice) in GetOptimum()
1500 if (nextOpt->price < kInfinityPrice in GetOptimum()
1503 || litPrice > nextOpt->price in GetOptimum()
1513 if (litPrice < nextOpt->price) in GetOptimum()
1515 nextOpt->price = litPrice; in GetOptimum()
1535 if (repMatchPrice < nextOpt->price) // 18.new in GetOptimum()
1538 // nextOpt->price >= kInfinityPrice || in GetOptimum()
1546 // if (shortRepPrice <= nextOpt->price) // 17.old in GetOptimum()
1547 if (shortRepPrice < nextOpt->price) // 18.new in GetOptimum()
1549 nextOpt->price = shortRepPrice; in GetOptimum()
1582 UInt32 price = litPrice + GetPrice_Rep_0(p, state2, posState2); in GetOptimum() local
1594 // price2 = price + GetPrice_Len_Rep_0(p, len, state2, posState2); in GetOptimum()
1595 price2 = price + GET_PRICE_LEN(&p->repLenEnc, posState2, len); in GetOptimum()
1599 if (price2 < opt->price) in GetOptimum()
1601 opt->price = price2; in GetOptimum()
1622 UInt32 price; in GetOptimum() local
1639 price = repMatchPrice + GetPrice_PureRep(p, repIndex, state, posState); in GetOptimum()
1642 UInt32 price2 = price + GET_PRICE_LEN(&p->repLenEnc, posState, len2); in GetOptimum()
1644 if (price2 < opt->price) in GetOptimum()
1646 opt->price = price2; in GetOptimum()
1675 price += GET_PRICE_LEN(&p->repLenEnc, posState, len) in GetOptimum()
1685 price += GetPrice_Rep_0(p, state2, posState2); in GetOptimum()
1703 // price2 = price + GetPrice_Len_Rep_0(p, len2, state2, posState2); in GetOptimum()
1704 price2 = price + GET_PRICE_LEN(&p->repLenEnc, posState2, len2); in GetOptimum()
1708 if (price2 < opt->price) in GetOptimum()
1710 opt->price = price2; in GetOptimum()
1759 UInt32 price = normalMatchPrice + GET_PRICE_LEN(&p->lenEnc, posState, len); in GetOptimum() local
1765 price += p->distancesPrices[lenNorm][dist & (kNumFullDistances - 1)]; in GetOptimum()
1767 price += p->posSlotPrices[lenNorm][posSlot] + p->alignPrices[dist & kAlignMask]; in GetOptimum()
1770 if (price < opt->price) in GetOptimum()
1772 opt->price = price; in GetOptimum()
1805 price += GET_PRICE_0(p->isMatch[state2][posState2]); in GetOptimum()
1806 price += LitEnc_Matched_GetPrice(LIT_PROBS(position + len, data[(size_t)len - 1]), in GetOptimum()
1813 price += GetPrice_Rep_0(p, state2, posState2); in GetOptimum()
1824 // price2 = price + GetPrice_Len_Rep_0(p, len2, state2, posState2); in GetOptimum()
1825 price2 = price + GET_PRICE_LEN(&p->repLenEnc, posState2, len2); in GetOptimum()
1828 if (price2 < opt->price) in GetOptimum()
1830 opt->price = price2; in GetOptimum()
1853 p->opt[last].price = kInfinityPrice; in GetOptimum()
2090 UInt32 price = 0; in FillAlignPrices() local
2095 bit = sym & 1; sym >>= 1; price += GET_PRICEa(probs[m], bit); m = (m << 1) + bit; in FillAlignPrices()
2096 bit = sym & 1; sym >>= 1; price += GET_PRICEa(probs[m], bit); m = (m << 1) + bit; in FillAlignPrices()
2097 bit = sym & 1; sym >>= 1; price += GET_PRICEa(probs[m], bit); m = (m << 1) + bit; in FillAlignPrices()
2099 p->alignPrices[i ] = price + GET_PRICEa_0(prob); in FillAlignPrices()
2100 p->alignPrices[i + 8] = price + GET_PRICEa_1(prob); in FillAlignPrices()
2123 UInt32 price = 0; in FillDistancesPrices() local
2134 price += GET_PRICEa(probs[m], bit); in FillDistancesPrices()
2141 tempPrices[base ] = price + GET_PRICEa_0(prob); in FillDistancesPrices()
2142 tempPrices[base + offset] = price + GET_PRICEa_1(prob); in FillDistancesPrices()
2156 UInt32 price; in FillDistancesPrices() local
2160 bit = sym & 1; sym >>= 1; price = GET_PRICEa(probs[sym], bit); in FillDistancesPrices()
2161 bit = sym & 1; sym >>= 1; price += GET_PRICEa(probs[sym], bit); in FillDistancesPrices()
2162 bit = sym & 1; sym >>= 1; price += GET_PRICEa(probs[sym], bit); in FillDistancesPrices()
2163 bit = sym & 1; sym >>= 1; price += GET_PRICEa(probs[sym], bit); in FillDistancesPrices()
2164 bit = sym & 1; sym >>= 1; price += GET_PRICEa(probs[sym], bit); in FillDistancesPrices()
2166 posSlotPrices[(size_t)slot * 2 ] = price + GET_PRICEa_0(prob); in FillDistancesPrices()
2167 posSlotPrices[(size_t)slot * 2 + 1] = price + GET_PRICEa_1(prob); in FillDistancesPrices()
2673 p->opt[i].price = kInfinityPrice; in LzmaEnc_Init()