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

Unified Diff: src/code-stub-assembler.h

Issue 2680973002: [stubs] Implement binary-search descriptor lookup in CSA (Closed)
Patch Set: graph_verifier++ Created 3 years, 10 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 | src/code-stub-assembler.cc » ('j') | src/code-stub-assembler.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/code-stub-assembler.h
diff --git a/src/code-stub-assembler.h b/src/code-stub-assembler.h
index cb1bd96a51a115905f20af824604d3ee68c75bc6..bf92bee7a0332ab60006690b5b89d6ae417245e4 100644
--- a/src/code-stub-assembler.h
+++ b/src/code-stub-assembler.h
@@ -753,7 +753,7 @@ class V8_EXPORT_PRIVATE CodeStubAssembler : public compiler::CodeAssembler {
Node* ToNumber(Node* context, Node* input);
// Converts |input| to one of 2^32 integer values in the range 0 through
- // 2^32−1, inclusive.
+ // 2^32-1, inclusive.
// ES#sec-touint32
compiler::Node* ToUint32(compiler::Node* context, compiler::Node* input);
@@ -1200,9 +1200,15 @@ class V8_EXPORT_PRIVATE CodeStubAssembler : public compiler::CodeAssembler {
inline void Print(Node* tagged_value) { return Print(nullptr, tagged_value); }
protected:
+ void DescriptorLookup(Node* unique_name, Node* descriptors, Node* bitfield3,
+ Label* if_found, Variable* var_name_index,
+ Label* if_not_found);
void DescriptorLookupLinear(Node* unique_name, Node* descriptors, Node* nof,
Label* if_found, Variable* var_name_index,
Label* if_not_found);
+ void DescriptorLookupBinary(Node* unique_name, Node* descriptors, Node* nof,
+ Label* if_found, Variable* var_name_index,
+ Label* if_not_found);
Node* CallGetterIfAccessor(Node* value, Node* details, Node* context,
Node* receiver, Label* if_bailout);
@@ -1241,6 +1247,19 @@ class V8_EXPORT_PRIVATE CodeStubAssembler : public compiler::CodeAssembler {
Node* AllocateConsString(Heap::RootListIndex map_root_index, Node* length,
Node* first, Node* second, AllocationFlags flags);
+ // Implements DescriptorArray::number_of_entries.
+ // Returns an untagged int32.
+ Node* DescriptorArrayNumberOfEntries(Node* descriptors);
+ // Implements DescriptorArray::ToKeyIndex.
+ // Returns an untagged IntPtr.
+ Node* DescriptorArrayToKeyIndex(Node* descriptor_number);
+ // Implements DescriptorArray::GetSortedKeyIndex.
+ // Returns an untagged int32.
+ Node* DescriptorArrayGetSortedKeyIndex(Node* descriptors,
+ Node* descriptor_number);
+ // Implements DescriptorArray::GetKey.
+ Node* DescriptorArrayGetKey(Node* descriptors, Node* descriptor_number);
+
static const int kElementLoopUnrollThreshold = 8;
};
« no previous file with comments | « no previous file | src/code-stub-assembler.cc » ('j') | src/code-stub-assembler.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698