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

Unified Diff: src/compiler/register-configuration.cc

Issue 1230473006: [turbofan] Use NumAllocatableRegisters() instead of kMaxNumAllocatableRegisters. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/register-configuration.cc
diff --git a/src/compiler/register-configuration.cc b/src/compiler/register-configuration.cc
index a3d3be1790a6a41ea64fb506f3be4b81d525fd3a..ebe6cfe23c34f3942b3945bc8d6f57687cbccedd 100644
--- a/src/compiler/register-configuration.cc
+++ b/src/compiler/register-configuration.cc
@@ -25,7 +25,7 @@ class ArchDefaultRegisterConfiguration : public RegisterConfiguration {
1,
1,
#else
- DoubleRegister::kMaxNumAllocatableRegisters,
+ DoubleRegister::NumAllocatableRegisters(),
DoubleRegister::NumAllocatableAliasedRegisters(),
#endif
general_register_name_table_,
@@ -35,7 +35,9 @@ class ArchDefaultRegisterConfiguration : public RegisterConfiguration {
for (int i = 0; i < Register::kMaxNumAllocatableRegisters; ++i) {
general_register_name_table_[i] = Register::AllocationIndexToString(i);
}
- for (int i = 0; i < DoubleRegister::kMaxNumAllocatableRegisters; ++i) {
+ DCHECK_GE(DoubleRegister::kMaxNumAllocatableRegisters,
+ DoubleRegister::NumAllocatableRegisters());
+ for (int i = 0; i < DoubleRegister::NumAllocatableRegisters(); ++i) {
double_register_name_table_[i] =
DoubleRegister::AllocationIndexToString(i);
}
« 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