Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(62)

Unified Diff: src/compiler/access-builder.cc

Issue 1216593003: [turbofan] Optimize string "length" property access based on types. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: REBASE Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « BUILD.gn ('k') | src/compiler/js-type-feedback-lowering.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/access-builder.cc
diff --git a/src/compiler/access-builder.cc b/src/compiler/access-builder.cc
index 5046fef5935c4b2ea66565491f3d7f272cfb4b44..a0225aa48987ef0942ac7a65d039538cec2fc661 100644
--- a/src/compiler/access-builder.cc
+++ b/src/compiler/access-builder.cc
@@ -115,7 +115,9 @@ FieldAccess AccessBuilder::ForMapInstanceType() {
// static
FieldAccess AccessBuilder::ForStringLength(Zone* zone) {
return {kTaggedBase, String::kLengthOffset, Handle<Name>(),
- Type::Range(0, String::kMaxLength, zone), kMachAnyTagged};
+ Type::Intersect(Type::Range(0, String::kMaxLength, zone),
+ Type::TaggedSigned(), zone),
+ kMachAnyTagged};
}
« no previous file with comments | « BUILD.gn ('k') | src/compiler/js-type-feedback-lowering.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698