llvm-6502/utils
Tom Stellard 898b9f020d TableGen: Generate a function for getting operand indices based on their defined names
This patch modifies TableGen to generate a function in
${TARGET}GenInstrInfo.inc called getNamedOperandIdx(), which can be used
to look up indices for operands based on their names.

In order to activate this feature for an instruction, you must set the
UseNamedOperandTable bit.

For example, if you have an instruction like:

def ADD : TargetInstr <(outs GPR:$dst), (ins GPR:$src0, GPR:$src1)>;

You can look up the operand indices using the new function, like this:

Target::getNamedOperandIdx(Target::ADD, Target::OpName::dst)  => 0
Target::getNamedOperandIdx(Target::ADD, Target::OpName::src0) => 1
Target::getNamedOperandIdx(Target::ADD, Target::OpName::src1) => 2

The operand names are case sensitive, so $dst and $DST are considered
different operands.

This change is useful for R600 which has instructions with a large number
of operands, many of which model single bit instruction configuration
values.  These configuration bits are common across most instructions,
but may have a different operand index depending on the instruction type.
It is useful to have a convenient way to look up the operand indices,
so these bits can be generically set on any instruction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@184879 91177308-0d34-0410-b5e6-96231b3b80d8
2013-06-25 21:22:09 +00:00
..
bugpoint
buildit Build Apple's llvmCore with --disable-zlib. <rdar://problem/14182316> 2013-06-18 01:22:29 +00:00
count
crosstool
emacs
FileCheck keep only the StringRef version of getFileOrSTDIN. 2013-06-25 05:28:34 +00:00
FileUpdate keep only the StringRef version of getFileOrSTDIN. 2013-06-25 05:28:34 +00:00
fpcmp Don't use PathV1.h in FileUtilities.h. 2013-06-13 20:41:00 +00:00
git
git-svn Use 'git svn find-rev' in git-svnrevert instead of shell script fu. 2013-04-26 03:27:39 +00:00
jedit
kate
KillTheDoctor
lint
lit Fixed bug when tests in executable partially used absolute paths. 2013-05-30 04:56:28 +00:00
llvm-build
llvm-lit
Misc
not Avoid using PathV1.h in Program.h. 2013-06-13 20:25:38 +00:00
PerfectShuffle
release Add a script to help us create source tar balls for the release. 2013-06-07 11:15:30 +00:00
TableGen TableGen: Generate a function for getting operand indices based on their defined names 2013-06-25 21:22:09 +00:00
Target/ARM
testgen
textmate
unittest Get the unittests compiling when building with cmake and the setting 2013-05-14 13:29:16 +00:00
valgrind
vim Enable syntax highlighting for reStructuredText files. 2013-02-28 06:43:24 +00:00
yaml-bench
check-each-file
clang-parse-diagnostics-file
codegen-diff
countloc.sh
DSAclean.py
DSAextract.py
findmisopt
findoptdiff
findsym.pl
GenLibDeps.pl
GetRepositoryPath
GetSourceVersion
getsrcs.sh
lldbDataFormatters.py
llvm-compilers-check
llvm-native-gcc
llvm-native-gxx
llvm.grm Unify clang/llvm attributes for asan/tsan/msan (LLVM part) 2013-02-26 06:58:09 +00:00
llvm.natvis
LLVMBuild.txt
llvmdo
llvmgrep
Makefile Move yaml2obj to tools too. 2013-04-05 20:00:35 +00:00
makellvm
profile.pl
sort_includes.py
test_debuginfo.pl
UpdateCMakeLists.pl
wciia.py