[LLVMdev] Inlining

Samuel Crow samuraileumas at yahoo.com
Sat Jan 9 10:00:43 PST 2010


Hello Dustin,

Always inline is the closest to a preprocessor macro you can get in LLVM Assembly since it doesn't have a preprocessor at all.  LLVM does aggressive inlining for functions used only once so those instances don't require specification as alwaysinline.

--Sam



----- Original Message ----
> From: Dustin Laurence <dllaurence at dslextreme.com>
> Cc: llvmdev at cs.uiuc.edu
> Sent: Sat, January 9, 2010 3:46:29 AM
> Subject: Re: [LLVMdev] Inlining
> 
> > Also, drop the alwaysinline attribute and '-always-inline' flag. The
> > normal inliner (aka. "opt -inline" which is run as part of "opt -O3")
> > should inline it.
> 
> Yes, it still did after I removed them.  Since I'm clearly not guessing
> well here, when would one want to use "alwaysinline"?
> 
> Dustin


      



More information about the llvm-dev mailing list