llvm-project/llvm/utils
Bruno Cardoso Lopes 2315beba24 Implement support for custom target specific asm parsing of operands.
Motivation: Improve the parsing of not usual (different from registers or
immediates) operand forms.

This commit implements only the generic support. The ARM specific modifications
will come next.

A table like the one below is autogenerated for every instruction
containing a 'ParserMethod' in its AsmOperandClass

static const OperandMatchEntry OperandMatchTable[20] = {
 /* Mnemonic, Operand List Mask, Operand Class, Features */
 { "cdp", 29 /* 0, 2, 3, 4 */, MCK_Coproc, Feature_IsThumb|Feature_HasV6 },
 { "cdp", 58 /* 1, 3, 4, 5 */, MCK_Coproc, Feature_IsARM },

A matcher function very similar (but lot more naive) to
MatchInstructionImpl scans the table. After the mnemonic match, the
features are checked and if the "to be parsed" operand index is
present in the mask, there's a real match. Then, a switch like the one
below dispatch the parsing to the custom method provided in
'ParseMethod':

 case MCK_Coproc:
   return TryParseCoprocessorOperandName(Operands);

llvm-svn: 125030
2011-02-07 19:38:32 +00:00
..
FileCheck MemoryBuffer now return an error_code and returns a OwningPtr<MemoryBuffer> via an out parm. 2010-12-16 03:29:14 +00:00
FileUpdate MemoryBuffer now return an error_code and returns a OwningPtr<MemoryBuffer> via an out parm. 2010-12-16 03:29:14 +00:00
KillTheDoctor Support/PathV1: Deprecate get{Basename,Dirname,Suffix}. 2010-12-18 22:23:07 +00:00
Misc
PerfectShuffle Teach PerfectShuffle to not generate files with embedded tab characters. 2010-10-14 00:12:49 +00:00
TableGen Implement support for custom target specific asm parsing of operands. 2011-02-07 19:38:32 +00:00
Target/ARM McARM: Write a silly Python script to compute some hard coded info from the 2011-01-11 19:06:26 +00:00
bugpoint
buildit I don't think I could find a 10.2.x box if I tried. 2011-01-08 01:52:20 +00:00
count Fix extra fread after EOF, non-wires-crossed version. 2010-06-01 14:09:29 +00:00
crosstool
emacs Using regexp-opt for keyword regex declarations makes the word lists more 2010-09-19 03:44:22 +00:00
fpcmp Merge System into Support. 2010-11-29 18:16:10 +00:00
git
jedit
kate syntax-highlighting: Fix module asm keyword. 2010-10-09 15:44:36 +00:00
lint
lit On Windows, replace each occurrence of '\' by '\\' on the replacement string. This is necessary to prevent re.sub from replacing escape sequences occurring in path. 2011-01-08 18:09:48 +00:00
llvm-lit CMake: Add llvm-lit to CMake build. 2010-09-13 17:52:38 +00:00
not Merge System into Support. 2010-11-29 18:16:10 +00:00
release Release-Asserts no longer exists. 2010-09-15 12:30:35 +00:00
unittest Make Win32's header file name lower for cross build on case-sensitive filesystem. 2011-02-04 12:53:04 +00:00
valgrind buildbot/valgrind: Ignore leaks in /usr/bin/as. 2010-08-25 03:40:20 +00:00
vim Enable clang autocompletion by default. 2010-10-26 23:24:54 +00:00
CollectDebugInfoUsingLLDB.py Update to match changes in lldb interface. 2011-02-01 21:47:35 +00:00
CompareDebugInfo.py Tidy up. 2011-01-31 21:16:37 +00:00
DSAclean.py
DSAextract.py
GenLibDeps.pl Per discussion with Sanjiv, remove the PIC16 target from mainline. When/if 2010-10-11 05:44:40 +00:00
GetRepositoryPath utils: Add GetRepositoryPath script, patch by Jonathan Mulder! 2010-09-29 17:57:01 +00:00
GetSourceVersion GetSourceVersion: Strip off svninfo extra markers, which aren't really part of the version. 2010-09-29 19:30:17 +00:00
Makefile remove reference to dead script. 2010-10-02 18:49:27 +00:00
NLT.schema
NewNightlyTest.pl Rename "Release" builds as "Release+Asserts"; rename "Release-Asserts" 2010-07-07 07:48:00 +00:00
NightlyTest.gnuplot
NightlyTestTemplate.html
UpdateCMakeLists.pl
cgiplotNLT.pl
check-each-file
codegen-diff
countloc.sh
findmisopt Convert a bunch of uses of 'bytecode' into 'bitcode'. This 2010-09-29 20:09:55 +00:00
findoptdiff Convert a bunch of uses of 'bytecode' into 'bitcode'. This 2010-09-29 20:09:55 +00:00
findsym.pl
getsrcs.sh
importNLT.pl
llvm-native-gcc Convert a bunch of uses of 'bytecode' into 'bitcode'. This 2010-09-29 20:09:55 +00:00
llvm-native-gxx Convert a bunch of uses of 'bytecode' into 'bitcode'. This 2010-09-29 20:09:55 +00:00
llvm.grm Don't worry about union types. 2010-08-29 14:50:21 +00:00
llvmdo Remove CVS artifacts. 2010-08-04 16:11:24 +00:00
llvmgrep
makellvm
parseNLT.pl
plotNLT.pl
profile.pl Convert a bunch of uses of 'bytecode' into 'bitcode'. This 2010-09-29 20:09:55 +00:00
test_debuginfo.pl Fix typo in temp. script file name. 2010-09-13 21:23:17 +00:00
webNLT.pl