[llvm-commits] [llvm] r112812 - in /llvm/trunk: lib/VMCore/AsmWriter.cpp test/Transforms/IndVarSimplify/2003-12-10-IndVarDeadCode.ll

Devang Patel dpatel at apple.com
Thu Sep 2 09:54:20 PDT 2010


On Sep 2, 2010, at 9:43 AM, Dan Gohman wrote:

> Also, in the case of functions with external linkage, the use count
> is more misleading than useful, because such functions may have
> any number of users outside their module.

It would be useful to print use count for functions with internal linkage, at least.

> And, the first line of function definitions is already a pretty
> crowded place, and it's liable to become more crowded in the future.
> 
> I've actually been considering removing use count printing altogether,

Please do not. I use it.

> possibly adding an AsmAnnotationWriter for printing use counts as an
> option when the information is actually desired.

If you want to omit undesired info in your eyes then I'd prefer that you add a option to omit #use count (say -fast-asmwriter :).

> 
> Another possibility is to suppress use counts for single-use
> instructions and global values with external linkage. This would
> reduce the clutter while still preserving the information that
> is useful.

That'd be very confusing for instructions. I'll have to guess whether this is single-use instruction or missing use count.
It'd be convenient to say "[#uses=unknown]" for global values with external linkage.

-
Devang



More information about the llvm-commits mailing list