[LLVMdev] (Possibly buggy?) doFinalization method behavior of FunctionPass
Owen Anderson
resistor at mac.com
Wed May 6 09:58:23 PDT 2015
Ah, actually, I was thinking of ModulePass::doFinalization. I’m not certain of the history of FunctionPass::doFinalization
—Owen
> On May 6, 2015, at 9:55 AM, John Criswell <jtcriswel at gmail.com> wrote:
>
> Dear Owen,
>
> First, to be sure we're on the same page, are we talking about doFinalization() in a FunctionPass or the doFinalization() method of another type of pass? I've been assuming that we're talking about FunctionPasses.
>
> Second, according to the documentation, FunctionPass::doInitialization() is allowed to modify the IR. The documentation on doFinalization() does not say anything either way on the matter.
>
> It sounds like there's a bug in the documentation. Would you like me to file a bug report?
>
> Regards,
>
> John Criswell
>
>
> On 5/6/15 12:45 PM, Owen Anderson wrote:
>>
>>> On May 6, 2015, at 7:28 AM, John Criswell <jtcriswel at gmail.com <mailto:jtcriswel at gmail.com>> wrote:
>>>
>>> My understanding is that doInitialization() and doFinalization() are designed specifically for modifying the LLVM IR (otherwise, why would a mutable reference to the Function be provided)?
>>
>> As the person whose use case motivated added them, we definitely didn’t intend them to be used for modifying IR.
>>
>> —Owen
>
>
> --
> John Criswell
> Assistant Professor
> Department of Computer Science, University of Rochester
> http://www.cs.rochester.edu/u/criswell <http://www.cs.rochester.edu/u/criswell>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150506/cf7b8932/attachment.html>
More information about the llvm-dev
mailing list