# operands < # args

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

# operands < # args

Ryan M. Lefever
In n transform I'm writing, when I call arg_size() on a variable
argument function similar to printf, it returns 1.  However when I call
getNumOperands() it returns 0.  Isn't an argument a type of operand? If
so, shouldn't the number of operands be at least as big as the number of
arguments?

Ryan


--
Ryan M. Lefever  [http://www.ews.uiuc.edu/~lefever]
_______________________________________________
LLVM Developers mailing list
[hidden email]         http://llvm.cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
Reply | Threaded
Open this post in threaded view
|

Re: # operands < # args

Chris Lattner
On Sun, 3 Dec 2006, Ryan M. Lefever wrote:
> In n transform I'm writing, when I call arg_size() on a variable
> argument function similar to printf, it returns 1.  However when I call
> getNumOperands() it returns 0.  Isn't an argument a type of operand?

Nope, arguments are not operands.  Functions never have operands.

-Chris

--
http://nondot.org/sabre/
http://llvm.org/
_______________________________________________
LLVM Developers mailing list
[hidden email]         http://llvm.cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev