Don't check symbol literals for being symbols.
R=fschneider@chromium.org Review URL: http://codereview.chromium.org/7312024 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8563 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
c1e1e97b8b
commit
0f9b0ad8c3
@ -784,6 +784,21 @@ void HChange::PrintDataTo(StringStream* stream) {
|
||||
}
|
||||
|
||||
|
||||
HValue* HCheckInstanceType::Canonicalize() {
|
||||
if (check_ == IS_STRING &&
|
||||
!value()->type().IsUninitialized() &&
|
||||
value()->type().IsString()) {
|
||||
return NULL;
|
||||
}
|
||||
if (check_ == IS_SYMBOL &&
|
||||
value()->IsConstant() &&
|
||||
HConstant::cast(value())->handle()->IsSymbol()) {
|
||||
return NULL;
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
void HCheckInstanceType::GetCheckInterval(InstanceType* first,
|
||||
InstanceType* last) {
|
||||
ASSERT(is_interval_check());
|
||||
|
@ -2003,14 +2003,7 @@ class HCheckInstanceType: public HUnaryOperation {
|
||||
virtual void Verify();
|
||||
#endif
|
||||
|
||||
virtual HValue* Canonicalize() {
|
||||
if (!value()->type().IsUninitialized() &&
|
||||
value()->type().IsString() &&
|
||||
check_ == IS_STRING) {
|
||||
return NULL;
|
||||
}
|
||||
return this;
|
||||
}
|
||||
virtual HValue* Canonicalize();
|
||||
|
||||
bool is_interval_check() const { return check_ <= LAST_INTERVAL_CHECK; }
|
||||
void GetCheckInterval(InstanceType* first, InstanceType* last);
|
||||
|
Loading…
Reference in New Issue
Block a user