[LLVMdev] Extracting all BasicBlocks of a Function into new Function
Chris Lattner
sabre at nondot.org
Tue Oct 3 14:58:15 PDT 2006
On Tue, 3 Oct 2006, Bram Adams wrote:
>> You'd have to change it to something like:
>> void foo(int X, ...) {
>> P = va_start();
>> bar(X, P);
>> }
>>
>> void bar(int X, valist P) {
>> use(P);
>> }
>
> Can the other va_...-intrinsics be used in bar as were the "P =
> va_start" in bar? The va_start probably is unnecessary now in bar,
> but where dus the va_end need to be: at the end of foo or of bar or
> doesn't it matter?
All the non-vastart calls can be anywhere. va_end in particular codegens
to a noop on all targets llvm currently supports, fwiw.
-Chris
--
http://nondot.org/sabre/
http://llvm.org/
More information about the llvm-dev
mailing list