Removed some useless/dead code regarding CompileTimeValues.

R=mstarzinger@chromium.org

Review URL: https://codereview.chromium.org/17580018

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@15300 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent a0f41ad3
......@@ -1829,10 +1829,7 @@ void FullCodeGenerator::VisitArrayLiteral(ArrayLiteral* expr) {
Expression* subexpr = subexprs->at(i);
// If the subexpression is a literal or a simple materialized literal it
// is already set in the cloned array.
if (subexpr->AsLiteral() != NULL ||
CompileTimeValue::IsCompileTimeValue(subexpr)) {
continue;
}
if (CompileTimeValue::IsCompileTimeValue(subexpr)) continue;
if (!result_saved) {
__ push(r0);
......
......@@ -1782,10 +1782,7 @@ void FullCodeGenerator::VisitArrayLiteral(ArrayLiteral* expr) {
Expression* subexpr = subexprs->at(i);
// If the subexpression is a literal or a simple materialized literal it
// is already set in the cloned array.
if (subexpr->AsLiteral() != NULL ||
CompileTimeValue::IsCompileTimeValue(subexpr)) {
continue;
}
if (CompileTimeValue::IsCompileTimeValue(subexpr)) continue;
if (!result_saved) {
__ push(eax); // array literal.
......
......@@ -1834,10 +1834,7 @@ void FullCodeGenerator::VisitArrayLiteral(ArrayLiteral* expr) {
Expression* subexpr = subexprs->at(i);
// If the subexpression is a literal or a simple materialized literal it
// is already set in the cloned array.
if (subexpr->AsLiteral() != NULL ||
CompileTimeValue::IsCompileTimeValue(subexpr)) {
continue;
}
if (CompileTimeValue::IsCompileTimeValue(subexpr)) continue;
if (!result_saved) {
__ push(v0); // array literal
......
......@@ -3734,18 +3734,6 @@ bool CompileTimeValue::IsCompileTimeValue(Expression* expression) {
}
bool CompileTimeValue::ArrayLiteralElementNeedsInitialization(
Expression* value) {
// If value is a literal the property value is already set in the
// boilerplate object.
if (value->AsLiteral() != NULL) return false;
// If value is a materialized literal the property value is already set
// in the boilerplate object if it is simple.
if (CompileTimeValue::IsCompileTimeValue(value)) return false;
return true;
}
Handle<FixedArray> CompileTimeValue::GetValue(Expression* expression) {
Factory* factory = Isolate::Current()->factory();
ASSERT(IsCompileTimeValue(expression));
......
......@@ -888,8 +888,6 @@ class CompileTimeValue: public AllStatic {
static bool IsCompileTimeValue(Expression* expression);
static bool ArrayLiteralElementNeedsInitialization(Expression* value);
// Get the value as a compile time value.
static Handle<FixedArray> GetValue(Expression* expression);
......
......@@ -1806,10 +1806,7 @@ void FullCodeGenerator::VisitArrayLiteral(ArrayLiteral* expr) {
Expression* subexpr = subexprs->at(i);
// If the subexpression is a literal or a simple materialized literal it
// is already set in the cloned array.
if (subexpr->AsLiteral() != NULL ||
CompileTimeValue::IsCompileTimeValue(subexpr)) {
continue;
}
if (CompileTimeValue::IsCompileTimeValue(subexpr)) continue;
if (!result_saved) {
__ push(rax); // array literal
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment