[LLVMdev] Question About Function Cloning

Tim Northover t.p.northover at gmail.com
Fri Oct 25 08:35:20 PDT 2013


Hi Arnamoy,

> Any idea, why the output looks like -

> Hello World
> Hello World
> val is 58
>
> While the it should print 4 times?

Both your loops are sharing the counter variable (%i1) without
resetting it to 0 in between calls. I think that accounts for the
behaviour.

Cheers.

Tim.



More information about the llvm-dev mailing list