[LLVMdev] PATCH: Use size reduction -- wave2

heisenbug ggreif at gmail.com
Wed Apr 16 03:07:45 PDT 2008


On Apr 16, 2:42 am, "Tanya M. Lattner" <to... at nondot.org> wrote:
> > Unfortunately I had to introduce a new GlobalVariable::Create
> > mechanism (I hoped to have nailed all in wave 1, but life is cruel).
> > I will submit scripts for the easy conversion of external projects
> > like the last time.
>
> One request is to explicity explain the new mechanism so people don't have
> to read the diffs or extrapolate from the conversion scripts.

Sure. The mechanism has been up to review here:

 <http://lists.cs.uiuc.edu/pipermail/llvmdev/2008-April/013729.html>
The header file should provide a nice overview:
 <http://llvm.org/viewvc/llvm-project/llvm/branches/ggreif/use-diet/
include/llvm/User.h?view=markup&pathrev=49380>

There is only one API change this time:
"new GlobalVariable" becomes "GlobalVariable::Create"
Currently there is another annoyance, you cannot pass a dereferenced
use_iterator to dyn_cast, you have to write dyn_cast<Foo>(I->get())
instead of the former dyn_cast<Foo>(*I). This turns out to be an ugly
performance bug in the current codebase (construction and destruction
of Use
objects without need). I am trying to come up with a syntactically
neutral
solution to this bug.


>
> Please send a separate email with what API changes occured and include
> "API Change" in the subject so its pretty clear whats happening. Advance
> notice as to when it will be merged in is also a plus.

Sure, will do so.

Cheers,

    Gabor

>
> Thanks,
> Tanya
>
>
>



More information about the llvm-dev mailing list