[PATCH] D25017: [mips][msa] Range check MSA intrinsics with immediates
Simon Dardis via cfe-commits
cfe-commits at lists.llvm.org
Wed Sep 28 05:49:36 PDT 2016
sdardis created this revision.
sdardis added reviewers: vkalintiris, zoran.jovanovic.
sdardis added a subscriber: cfe-commits.
Herald added a subscriber: sdardis.
This patch teaches clang to range check immediates for MIPS MSA instrincs. This
checking is done strictly in comparison to some existing GCC implementations.
E.g. __msa_andvi_b(var, 257) does not result in andvi $wX, 1. Similarily
__msa_ldi_b takes a range of -128 to 127.
As part of this effort, correct the existing MSA test as it has both illegal types and
immediates.
https://reviews.llvm.org/D25017
Files:
lib/Sema/SemaChecking.cpp
test/CodeGen/builtins-mips-msa-error.c
test/CodeGen/builtins-mips-msa.c
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D25017.72810.patch
Type: text/x-patch
Size: 58363 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20160928/425ef055/attachment-0001.bin>
More information about the cfe-commits
mailing list