Changeset 5611 for icGREP/icgrepdevel/icgrep
 Timestamp:
 Aug 14, 2017, 9:52:32 PM (2 years ago)
 Location:
 icGREP/icgrepdevel/icgrep/kernels
 Files:

 2 edited
Legend:
 Unmodified
 Added
 Removed

icGREP/icgrepdevel/icgrep/kernels/interface.cpp
r5552 r5611 86 86 87 87 unsigned ProcessingRate::calculateMaxReferenceItems(unsigned outputItems, bool doFinal) const { 88 if (mKind == ProcessingRate::ProcessingRateKind::FixedRatio ) {88 if (mKind == ProcessingRate::ProcessingRateKind::FixedRatio  mKind == ProcessingRate::ProcessingRateKind::MaxRatio) { 89 89 if (mRatioNumerator == mRatioDenominator) { 90 90 return outputItems; … … 98 98 return doFinal ? outputItems  1 : outputItems; 99 99 } 100 report_fatal_error("Inverse processing rate calculation attempted for variable orunknown rate.");100 report_fatal_error("Inverse processing rate calculation attempted for unknown rate."); 101 101 } 102 102 103 103 Value * ProcessingRate::CreateMaxReferenceItemsCalculation(IDISA::IDISA_Builder * const b, Value * outputItems, Value * doFinal) const { 104 if (mKind == ProcessingRate::ProcessingRateKind::FixedRatio ) {104 if (mKind == ProcessingRate::ProcessingRateKind::FixedRatio  mKind == ProcessingRate::ProcessingRateKind::MaxRatio) { 105 105 if (mRatioNumerator == mRatioDenominator) { 106 106 return outputItems; … … 123 123 return b>CreateSub(outputItems, ConstantInt::get(T, 1)); 124 124 } 125 report_fatal_error("Inverse processing rate calculation attempted for variable orunknown rate.");125 report_fatal_error("Inverse processing rate calculation attempted for unknown rate."); 126 126 } 127 127 
icGREP/icgrepdevel/icgrep/kernels/interface.h
r5590 r5611 42 42 bool isUnknownRate() const { return mKind == ProcessingRateKind::Unknown; } 43 43 unsigned calculateRatio(unsigned referenceItems, bool doFinal = false) const; 44 // Calculate the max number of reference items that can be processed without exceeding/exhausting outputItems 44 45 unsigned calculateMaxReferenceItems(unsigned outputItems, bool doFinal = false) const; 45 46 llvm::Value * CreateRatioCalculation(IDISA::IDISA_Builder * const b, llvm::Value * referenceItems, llvm::Value * doFinal = nullptr) const;
Note: See TracChangeset
for help on using the changeset viewer.