projects
/
platform
/
upstream
/
coreclr.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e966022
)
Return null for unexpected HW intrinsic (#24219)
author
Carol Eidt
<carol.eidt@microsoft.com>
Thu, 25 Apr 2019 14:26:21 +0000
(07:26 -0700)
committer
GitHub
<noreply@github.com>
Thu, 25 Apr 2019 14:26:21 +0000
(07:26 -0700)
Fix #17815
src/jit/hwintrinsicxarch.cpp
patch
|
blob
|
history
diff --git
a/src/jit/hwintrinsicxarch.cpp
b/src/jit/hwintrinsicxarch.cpp
index
8da12e5
..
4d78fde
100644
(file)
--- a/
src/jit/hwintrinsicxarch.cpp
+++ b/
src/jit/hwintrinsicxarch.cpp
@@
-846,8
+846,11
@@
GenTree* Compiler::impHWIntrinsic(NamedIntrinsic intrinsic,
var_types argType = TYP_UNKNOWN;
assert(numArgs >= 0);
- assert(HWIntrinsicInfo::lookupIns(intrinsic, baseType) != INS_invalid);
- assert(simdSize == 32 || simdSize == 16);
+ if ((HWIntrinsicInfo::lookupIns(intrinsic, baseType) == INS_invalid) || ((simdSize != 32) && (simdSize != 16)))
+ {
+ assert(!"Unexpected HW Intrinsic");
+ return nullptr;
+ }
GenTreeHWIntrinsic* retNode = nullptr;
GenTree* op1 = nullptr;