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

Unified Diff: src/code-stubs.cc

Issue 1150673002: Add a TurboFan skeleton for StringAddStub. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fixed frame construction logic Created 5 years, 7 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 | « src/code-stubs.h ('k') | src/compiler/arm/code-generator-arm.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/code-stubs.cc
diff --git a/src/code-stubs.cc b/src/code-stubs.cc
index 774623e492924a9d10d4eab822885fd9fdc04597..a1437ece39bf287cc370142336cbcd4c87f35040 100644
--- a/src/code-stubs.cc
+++ b/src/code-stubs.cc
@@ -315,18 +315,29 @@ void BinaryOpICWithAllocationSiteStub::GenerateAheadOfTime(
}
-void StringAddStub::PrintBaseName(std::ostream& os) const { // NOLINT
- os << "StringAddStub";
- if ((flags() & STRING_ADD_CHECK_BOTH) == STRING_ADD_CHECK_BOTH) {
- os << "_CheckBoth";
- } else if ((flags() & STRING_ADD_CHECK_LEFT) == STRING_ADD_CHECK_LEFT) {
- os << "_CheckLeft";
- } else if ((flags() & STRING_ADD_CHECK_RIGHT) == STRING_ADD_CHECK_RIGHT) {
- os << "_CheckRight";
- }
- if (pretenure_flag() == TENURED) {
- os << "_Tenured";
+std::ostream& operator<<(std::ostream& os, const StringAddFlags& flags) {
+ switch (flags) {
+ case STRING_ADD_CHECK_NONE:
+ return os << "CheckNone";
+ case STRING_ADD_CHECK_LEFT:
+ return os << "CheckLeft";
+ case STRING_ADD_CHECK_RIGHT:
+ return os << "CheckRight";
+ case STRING_ADD_CHECK_BOTH:
+ return os << "CheckBoth";
}
+ UNREACHABLE();
+ return os;
+}
+
+
+void StringAddStub::PrintBaseName(std::ostream& os) const { // NOLINT
+ os << "StringAddStub_" << flags() << "_" << pretenure_flag();
+}
+
+
+void StringAddTFStub::PrintBaseName(std::ostream& os) const { // NOLINT
+ os << "StringAddTFStub_" << flags() << "_" << pretenure_flag();
}
« no previous file with comments | « src/code-stubs.h ('k') | src/compiler/arm/code-generator-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698