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

Unified Diff: src/builtins/builtins-string-gen.cc

Issue 2923183002: [string] Re-enable result caching for String.p.split (Closed)
Patch Set: Tweak Created 3 years, 6 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/builtins/builtins-string-gen.cc
diff --git a/src/builtins/builtins-string-gen.cc b/src/builtins/builtins-string-gen.cc
index 5517b113d9013794fcc3ed175cc28d9b8ffed872..f56a5e846765bab9aecd3e6175918227a66051bd 100644
--- a/src/builtins/builtins-string-gen.cc
+++ b/src/builtins/builtins-string-gen.cc
@@ -1393,13 +1393,10 @@ TF_BUILTIN(StringPrototypeSplit, StringBuiltinsAssembler) {
});
// String and integer conversions.
- // TODO(jgruber): The old implementation used Uint32Max instead of SmiMax -
- // but AFAIK there should not be a difference since arrays are capped at Smi
- // lengths.
Node* const subject_string = ToString_Inline(context, receiver);
Node* const limit_number =
- Select(IsUndefined(limit), [=]() { return SmiConstant(Smi::kMaxValue); },
+ Select(IsUndefined(limit), [=]() { return NumberConstant(kMaxUInt32); },
[=]() { return ToUint32(context, limit); },
MachineRepresentation::kTagged);
Node* const separator_string = ToString_Inline(context, separator);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698