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

Unified Diff: src/x64/code-stubs-x64.h

Issue 542613003: Introduce code stub constructors for stub keys. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: define MajorKey inline Created 6 years, 3 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
Index: src/x64/code-stubs-x64.h
diff --git a/src/x64/code-stubs-x64.h b/src/x64/code-stubs-x64.h
index c8e3835dc46348349ce56b03d37dc87e9b91b6a4..df597ce6a6954008bc253d3f5ba8b798091731fd 100644
--- a/src/x64/code-stubs-x64.h
+++ b/src/x64/code-stubs-x64.h
@@ -5,8 +5,6 @@
#ifndef V8_X64_CODE_STUBS_X64_H_
#define V8_X64_CODE_STUBS_X64_H_
-#include "src/code-stubs.h"
-
namespace v8 {
namespace internal {
@@ -25,7 +23,6 @@ class StringHelper : public AllStatic {
Register count,
String::Encoding encoding);
-
// Generate string hash.
static void GenerateHashInit(MacroAssembler* masm,
Register hash,
@@ -110,8 +107,6 @@ class NameDictionaryLookupStub: public PlatformCodeStub {
NameDictionary::kHeaderSize +
NameDictionary::kElementsStartIndex * kPointerSize;
- virtual inline Major MajorKey() const FINAL OVERRIDE;
-
Register dictionary() const {
return Register::from_code(DictionaryBits::decode(minor_key_));
}
@@ -131,7 +126,7 @@ class NameDictionaryLookupStub: public PlatformCodeStub {
class IndexBits: public BitField<int, 8, 4> {};
class LookupModeBits: public BitField<LookupMode, 12, 1> {};
- DISALLOW_COPY_AND_ASSIGN(NameDictionaryLookupStub);
+ DEFINE_CODE_STUB(NameDictionaryLookup, PlatformCodeStub);
};
@@ -151,6 +146,9 @@ class RecordWriteStub: public PlatformCodeStub {
SaveFPRegsModeBits::encode(fp_mode);
}
+ RecordWriteStub(uint32_t key, Isolate* isolate)
+ : PlatformCodeStub(key, isolate), regs_(object(), address(), value()) {}
+
enum Mode {
STORE_BUFFER_ONLY,
INCREMENTAL,
@@ -334,7 +332,7 @@ class RecordWriteStub: public PlatformCodeStub {
kUpdateRememberedSetOnNoNeedToInformIncrementalMarker
};
- virtual inline Major MajorKey() const FINAL OVERRIDE;
+ virtual Major MajorKey() const FINAL OVERRIDE { return RecordWrite; }
void Generate(MacroAssembler* masm);
void GenerateIncremental(MacroAssembler* masm, Mode mode);
« no previous file with comments | « src/objects.cc ('k') | test/cctest/test-code-stubs.cc » ('j') | test/cctest/test-code-stubs.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698