llvm-project/llvm/utils
Matt Arsenault b4a647449f TableGen/GlobalISel: Add way for SDNodeXForm to work on timm
The current implementation assumes there is an instruction associated
with the transform, but this is not the case for
timm/TargetConstant/immarg values. These transforms should directly
operate on a specific MachineOperand in the source
instruction. TableGen would assert if you attempted to define an
equivalent GISDNodeXFormEquiv using timm when it failed to find the
instruction matcher.

Specially recognize SDNodeXForms on timm, and pass the operand index
to the render function.

Ideally this would be a separate render function type that looks like
void renderFoo(MachineInstrBuilder, const MachineOperand&), but this
proved to be somewhat mechanically painful. Add an optional operand
index which will only be passed if the transform should only look at
the one source operand.

Theoretically it would also be possible to only ever pass the
MachineOperand, and the existing renderers would check the parent. I
think that would be somewhat ugly for the standard usage which may
want to inspect other operands, and I also think MachineOperand should
eventually not carry a pointer to the parent instruction.

Use it in one sample pattern. This isn't a great example, since the
transform exists to satisfy DAG type constraints. This could also be
avoided by just changing the MachineInstr's arbitrary choice of
operand type from i16 to i32. Other patterns have nontrivial uses, but
this serves as the simplest example.

One flaw this still has is if you try to use an SDNodeXForm defined
for imm, but the source pattern uses timm, you still see the "Failed
to lookup instruction" assert. However, there is now a way to avoid
it.
2020-01-09 17:37:52 -05:00
..
FileCheck [FileCheck] Given multiple -dump-input, prefer most verbose 2019-12-03 14:21:13 -05:00
KillTheDoctor Revert "Use InitLLVM to setup a pretty stack printer" 2019-11-25 21:06:56 -05:00
LLVMVisualizers Clean up MSVC visualization of LLVM pointer types 2019-06-30 21:54:34 +00:00
Misc
PerfectShuffle
Reviewing [find_interesting_reviews.py] Add git blame output cache 2019-12-23 12:08:16 +00:00
TableGen TableGen/GlobalISel: Add way for SDNodeXForm to work on timm 2020-01-09 17:37:52 -05:00
Target/ARM
UpdateTestChecks update_test_checks: match CHECK-EMPTY lines for replacement. 2020-01-02 12:17:37 -05:00
benchmark [benchmark] Fix win32 link on case-sensitive fs 2019-07-30 20:47:59 +00:00
bugpoint [NFC] Fix trivial typos in comments 2020-01-06 10:50:26 +00:00
count
crosstool
docker
emacs [NFC][emacs] remove out-of-date comment from tablegen-mode.el 2019-09-26 19:36:01 +00:00
fpcmp
gdb-scripts Add gdb pretty printer for MutableArrayRef, remove ConstArrayRef. 2020-01-09 22:43:45 +01:00
git-svn git-llvm: Add option to push to Github with SSH 2019-12-16 16:51:43 -05:00
gn [gn build] Port 346f6b54bd 2020-01-08 13:43:29 +00:00
jedit
kate [kate] Add various missing keywords 2019-11-19 09:54:07 +00:00
lint
lit Make check-llvm run 50% faster on macOS, 18% faster on Windows. 2020-01-06 12:57:42 -05:00
llvm-build Write the RequiredLibraries for 'all' in LibraryDependencies.inc in a deterministic order (PR42739) 2019-08-05 13:04:07 +00:00
llvm-lit
llvm-locstats Re-land "[cmake] Add dependency on llvm-dwarfdump to llvm-locstats" 2019-12-20 09:11:07 +00:00
not
release export.sh: Fetch sources from GitHub instead of SVN 2019-12-06 18:57:08 -08:00
sanitizers
testgen
textmate
unittest Add a default copy constructor for -Wdeprecated-copy warnings. 2019-12-05 14:16:04 -08:00
valgrind
vim [X86] Add new calling convention that guarantees tail call optimization 2019-10-07 22:28:58 +00:00
vscode
yaml-bench
DSAclean.py
DSAextract.py
GenLibDeps.pl [Bitcode] Move Bitstream to a separate library 2019-07-03 22:40:07 +00:00
GetRepositoryPath
GetSourceVersion
LLVMBuild.txt
UpdateCMakeLists.pl
abtest.py
add_argument_names.py IR: print value numbers for unnamed function arguments 2019-08-03 14:28:34 +00:00
bisect [utils] Fix incompatibility of bisect[-skip-count] with Python 3 2019-10-04 16:44:18 +00:00
bisect-skip-count [utils] Fix incompatibility of bisect[-skip-count] with Python 3 2019-10-04 16:44:18 +00:00
bugpoint_gisel_reducer.py
check-each-file
chunk-print-before-all.py [Util] Add a helper script for converting -print-before-all output into a file based equivelent 2019-06-19 22:05:47 +00:00
clang-parse-diagnostics-file
codegen-diff
collect_and_build_with_pgo.py
countloc.sh
create_ladder_graph.py
demangle_tree.py
extract_symbols.py Use portable flag with nm in extract_symbols.py 2019-10-23 16:48:22 -04:00
extract_vplan.py
findmisopt
findoptdiff
findsym.pl
getsrcs.sh
indirect_calls.py
lldbDataFormatters.py Add LLDB dataformatters for llvm::StringRef and lldb_private::ConstString 2019-08-16 23:47:57 +00:00
llvm-compilers-check
llvm-gisel-cov.py
llvm-native-gxx
llvm.grm
llvmdo
llvmgrep
prepare-code-coverage-artifact.py svn propset svn:executable on utils/prepare-code-coverage-artifact.py 2019-06-04 23:35:07 +00:00
schedcover.py
shuffle_fuzz.py
shuffle_select_fuzz_tester.py
sort_includes.py
unicode-case-fold.py
update_analyze_test_checks.py [UpdateTestChecks] Change shebang from python to python3 2019-12-03 13:50:07 -08:00
update_cc_test_checks.py Make mangled_names.test and update_cc_test_checks.py work with Python 2. 2020-01-02 13:45:39 -05:00
update_llc_test_checks.py [UpdateTestChecks] Change shebang from python to python3 2019-12-03 13:50:07 -08:00
update_mca_test_checks.py [UpdateTestChecks] Change shebang from python to python3 2019-12-03 13:50:07 -08:00
update_mir_test_checks.py [UpdateTestChecks] Change shebang from python to python3 2019-12-03 13:50:07 -08:00
update_test_checks.py [Utils] Allow update_test_checks to scrub attribute annotations 2019-12-31 01:51:22 -06:00
wciia.py