[llvm-commits] [llvm] r84292 - in /llvm/trunk: examples/BrainF/ include/llvm/ lib/AsmParser/ lib/Bitcode/Reader/ lib/Transforms/IPO/ lib/Transforms/Scalar/ lib/VMCore/ test/Transforms/GlobalOpt/ test/Transforms/IndMemRem/ test/Transforms/InstCombine/
Nick Lewycky
nicholas at mxc.ca
Sat Oct 17 22:38:39 PDT 2009
Chris Lattner wrote:
>> + if (!realMallocF->doesNotAlias(0)) realMallocF-
>>> setDoesNotAlias(0);
>
> I don't think you have to care about this. We don't care that old
> code be performant, just that it work.
Really? Is it that bad to just leave this in?
>> + // "autoupgrade_malloc" updated to "malloc" in
>> ValidateEndOfModule().
>> +
>> + Inst = cast<Instruction>(CallInst::CreateMalloc(BB, IntPtrTy, Ty,
>> + Size, MallocF));
>
> CreateMalloc doesn't return something convertible to Instruction? Why
> do you need the cast<>?
I committed a patch to change it to return Instruction* earlier today. I
didn't check for extraneous cast<Instruction>'s though, those should
still be cleaned up.
Nick
More information about the llvm-commits
mailing list