Support loading constant functions in hydrogen.
Review URL: http://codereview.chromium.org/5878004 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@6057 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
73737fcdb6
commit
2ba48c0a45
@ -3614,6 +3614,11 @@ HInstruction* HGraphBuilder::BuildLoadNamed(HValue* obj,
|
|||||||
map,
|
map,
|
||||||
&lookup,
|
&lookup,
|
||||||
true);
|
true);
|
||||||
|
} else if (lookup.IsProperty() && lookup.type() == CONSTANT_FUNCTION) {
|
||||||
|
AddInstruction(new HCheckNonSmi(obj));
|
||||||
|
AddInstruction(new HCheckMap(obj, map));
|
||||||
|
Handle<JSFunction> function(lookup.GetConstantFunctionFromMap(*map));
|
||||||
|
return new HConstant(function, Representation::Tagged());
|
||||||
} else {
|
} else {
|
||||||
return BuildLoadNamedGeneric(obj, expr);
|
return BuildLoadNamedGeneric(obj, expr);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user