aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode/Writer/BitWriter.cpp
diff options
context:
space:
mode:
authorDiana Picus <diana.picus@linaro.org>2017-06-15 10:53:31 +0000
committerDiana Picus <diana.picus@linaro.org>2017-06-15 10:53:31 +0000
commit02e11010b2d46b231f2fd925e5c5b76f0811ccb4 (patch)
tree2669f0869156538b0e1f92b9287af8ae6df7565b /llvm/lib/Bitcode/Writer/BitWriter.cpp
parent8fd1601d322235b34f97505f795f83f56be587c1 (diff)
downloadllvm-02e11010b2d46b231f2fd925e5c5b76f0811ccb4.zip
llvm-02e11010b2d46b231f2fd925e5c5b76f0811ccb4.tar.gz
llvm-02e11010b2d46b231f2fd925e5c5b76f0811ccb4.tar.bz2
[ARM] GlobalISel: Add support for i32 modulo
Add support for modulo for targets that have hardware division and for those that don't. When hardware division is not available, we have to choose the correct libcall to use. This is generally straightforward, except for AEABI. The AEABI variant is trickier than the other libcalls because it returns { quotient, remainder }, instead of just one value like the other libcalls that we've seen so far. Therefore, we need to use custom lowering for it. However, we don't want to have too much special code, so we refactor the target-independent code in the legalizer by adding a helper for replacing an instruction with a libcall. This helper is used by the legalizer itself when dealing with simple calls, and also by the custom ARM legalization for the more complicated AEABI divmod calls. llvm-svn: 305459
Diffstat (limited to 'llvm/lib/Bitcode/Writer/BitWriter.cpp')
0 files changed, 0 insertions, 0 deletions