[llvm-commits] [llvm] r134127 - in /llvm/trunk: include/llvm/MC/ include/llvm/Target/ lib/ExecutionEngine/ lib/MC/ lib/MC/MCDisassembler/ lib/Target/ARM/ lib/Target/ARM/AsmParser/ lib/Target/Alpha/ lib/Target/Blackfin/ lib/Target/CBackend/ lib/Target/CellSPU/ lib/Target/CppBackend/ lib/Target/MBlaze/ lib/Target/MBlaze/AsmParser/ lib/Target/MSP430/ lib/Target/Mips/ lib/Target/PTX/ lib/Target/PowerPC/ lib/Target/Sparc/ lib/Target/SystemZ/ lib/Target/X86/ lib/Target/XCore/ tools/llc/ tools/llvm-mc/ tools/llvm-objdump/ too...

Chris Lattner clattner at apple.com
Thu Jun 30 13:14:37 PDT 2011


On Jun 29, 2011, at 6:53 PM, Evan Cheng wrote:

> Author: evancheng
> Date: Wed Jun 29 20:53:36 2011
> New Revision: 134127
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=134127&view=rev
> Log:
> Fix the ridiculous SubtargetFeatures API where it implicitly expects CPU name to
> be the first encoded as the first feature. It then uses the CPU name to look up
> features / scheduling itineray even though clients know full well the CPU name
> being used to query these properties.
> 
> The fix is to just have the clients explictly pass the CPU name!

Nice!  Please make APIs like the getFeatureBits and getItinerary methods take a StringRef though, instead of const std::string&.

-Chris



More information about the llvm-commits mailing list