Changeset 180595 in webkit for trunk/Source/JavaScriptCore/dfg/DFGJITCode.cpp
- Timestamp:
- Feb 24, 2015, 4:41:35 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/dfg/DFGJITCode.cpp
r164229 r180595 83 83 84 84 result = Operands<JSValue>(OperandsLike, recoveries); 85 for (size_t i = result.size(); i--;) { 86 int operand = result.operandForIndex(i); 87 88 if (codeOrigin == CodeOrigin(0) 89 && operandIsArgument(operand) 90 && !VirtualRegister(operand).toArgument() 91 && codeBlock->codeType() == FunctionCode 92 && codeBlock->specializationKind() == CodeForConstruct) { 93 // Ugh. If we're in a constructor, the 'this' argument may hold garbage. It will 94 // also never be used. It doesn't matter what we put into the value for this, 95 // but it has to be an actual value that can be grokked by subsequent DFG passes, 96 // so we sanitize it here by turning it into Undefined. 97 result[i] = jsUndefined(); 98 continue; 99 } 100 85 for (size_t i = result.size(); i--;) 101 86 result[i] = recoveries[i].recover(exec); 102 }103 87 } 104 88
Note:
See TracChangeset
for help on using the changeset viewer.