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:
97d1972
)
Fix Valuenum:EvalFuncForConstantArgs (#17506)
author
Sergey Andreenko
<seandree@microsoft.com>
Wed, 11 Apr 2018 20:16:22 +0000
(13:16 -0700)
committer
GitHub
<noreply@github.com>
Wed, 11 Apr 2018 20:16:22 +0000
(13:16 -0700)
src/jit/valuenum.cpp
patch
|
blob
|
history
diff --git
a/src/jit/valuenum.cpp
b/src/jit/valuenum.cpp
index
fcb38d3
..
15a970d
100644
(file)
--- a/
src/jit/valuenum.cpp
+++ b/
src/jit/valuenum.cpp
@@
-1098,6
+1098,11
@@
ValueNum ValueNumStore::VNForFunc(var_types typ, VNFunc func, ValueNum arg0VN, V
{
canFold = false;
}
+ if (typ == TYP_BYREF)
+ {
+ // We don't want to fold expressions that produce TYP_BYREF
+ canFold = false;
+ }
if (canFold)
{
@@
-1752,12
+1757,6
@@
ValueNum ValueNumStore::EvalFuncForConstantArgs(var_types typ, VNFunc func, Valu
return EvalCastForConstantArgs(typ, func, arg0VN, arg1VN);
}
- if (typ == TYP_BYREF)
- {
- // We don't want to fold expressions that produce TYP_BYREF
- return false;
- }
-
var_types arg0VNtyp = TypeOfVN(arg0VN);
var_types arg1VNtyp = TypeOfVN(arg1VN);