[llvm-commits] Fix for PR1798 (ScalarEvolution)

Nick Lewycky nicholas at mxc.ca
Sun Feb 10 14:45:06 PST 2008

Chris Lattner wrote:
> On Feb 9, 2008, at 9:26 AM, Wojciech Matyjewicz wrote:
>> Hi,
>> I've attached an updated version of the patch. It is ready for using
>> support for APInts in the code generator, but currently it doesn't  
>> rely
>> on this feature. I've added a hack that rounds up the computation
>> bitwidth to power of 2 (only these bitwidths are allowed: 1, 2, ...,
>> 64). Hack is visible and very easy to remove in future.
>> Is it safe to commit it now?
> The patch looks good to me.  Nicholas, can you please review it also?   
> If Nicholas likes it, please commit,

Just one question,

+  const IntegerType *ExTy = IntegerType::get(std::max(DividendBits, 32U));

why the max of DividendBits and 32? If for whatever reason we think we 
need only 16 bits for the computation, why expand it to 32?


More information about the llvm-commits mailing list