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

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

Issue 2456193005: [stubs] Remove CSA::AssertInstanceType() in favour of CSA_ASSERT(HasInstanceType()). (Closed)
Patch Set: Created 4 years, 2 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-stub-assembler.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/code-stub-assembler.cc
diff --git a/src/code-stub-assembler.cc b/src/code-stub-assembler.cc
index 4e18e34bbaaab4a567a44bbd3eed24ba97e2ebd8..a330996159fd1fa3e351e368a78813e8fa672d98 100644
--- a/src/code-stub-assembler.cc
+++ b/src/code-stub-assembler.cc
@@ -1000,11 +1000,6 @@ Node* CodeStubAssembler::HasInstanceType(Node* object,
return Word32Equal(LoadInstanceType(object), Int32Constant(instance_type));
}
-void CodeStubAssembler::AssertInstanceType(Node* object,
- InstanceType instance_type) {
- CSA_ASSERT(HasInstanceType(object, instance_type));
-}
-
Node* CodeStubAssembler::LoadProperties(Node* object) {
return LoadObjectField(object, JSObject::kPropertiesOffset);
}
@@ -4383,7 +4378,7 @@ Node* CodeStubAssembler::CallGetterIfAccessor(Node* value, Node* details,
GotoIf(Word32Equal(LoadInstanceType(accessor_pair),
Int32Constant(ACCESSOR_INFO_TYPE)),
if_bailout);
- AssertInstanceType(accessor_pair, ACCESSOR_PAIR_TYPE);
+ CSA_ASSERT(HasInstanceType(accessor_pair, ACCESSOR_PAIR_TYPE));
Node* getter = LoadObjectField(accessor_pair, AccessorPair::kGetterOffset);
Node* getter_map = LoadMap(getter);
Node* instance_type = LoadMapInstanceType(getter_map);
@@ -4538,7 +4533,7 @@ void CodeStubAssembler::TryLookupElement(Node* object, Node* map,
}
Bind(&if_isfaststringwrapper);
{
- AssertInstanceType(object, JS_VALUE_TYPE);
+ CSA_ASSERT(HasInstanceType(object, JS_VALUE_TYPE));
Node* string = LoadJSValueValue(object);
CSA_ASSERT(IsStringInstanceType(LoadInstanceType(string)));
Node* length = LoadStringLength(string);
@@ -4547,7 +4542,7 @@ void CodeStubAssembler::TryLookupElement(Node* object, Node* map,
}
Bind(&if_isslowstringwrapper);
{
- AssertInstanceType(object, JS_VALUE_TYPE);
+ CSA_ASSERT(HasInstanceType(object, JS_VALUE_TYPE));
Node* string = LoadJSValueValue(object);
CSA_ASSERT(IsStringInstanceType(LoadInstanceType(string)));
Node* length = LoadStringLength(string);
@@ -6157,11 +6152,11 @@ void CodeStubAssembler::LoadGlobalIC(const LoadICParameters* p) {
Label try_handler(this), miss(this);
Node* weak_cell =
LoadFixedArrayElement(p->vector, p->slot, 0, SMI_PARAMETERS);
- AssertInstanceType(weak_cell, WEAK_CELL_TYPE);
+ CSA_ASSERT(HasInstanceType(weak_cell, WEAK_CELL_TYPE));
// Load value or try handler case if the {weak_cell} is cleared.
Node* property_cell = LoadWeakCellValue(weak_cell, &try_handler);
- AssertInstanceType(property_cell, PROPERTY_CELL_TYPE);
+ CSA_ASSERT(HasInstanceType(property_cell, PROPERTY_CELL_TYPE));
Node* value = LoadObjectField(property_cell, PropertyCell::kValueOffset);
GotoIf(WordEqual(value, TheHoleConstant()), &miss);
@@ -6175,7 +6170,7 @@ void CodeStubAssembler::LoadGlobalIC(const LoadICParameters* p) {
&miss);
// In this case {handler} must be a Code object.
- AssertInstanceType(handler, CODE_TYPE);
+ CSA_ASSERT(HasInstanceType(handler, CODE_TYPE));
LoadWithVectorDescriptor descriptor(isolate());
Node* native_context = LoadNativeContext(p->context);
Node* receiver =
@@ -8646,7 +8641,7 @@ compiler::Node* CodeStubAssembler::AllocateJSArrayIterator(
}
compiler::Node* CodeStubAssembler::IsDetachedBuffer(compiler::Node* buffer) {
- AssertInstanceType(buffer, JS_ARRAY_BUFFER_TYPE);
+ CSA_ASSERT(HasInstanceType(buffer, JS_ARRAY_BUFFER_TYPE));
Node* buffer_bit_field = LoadObjectField(
buffer, JSArrayBuffer::kBitFieldOffset, MachineType::Uint32());
« no previous file with comments | « src/code-stub-assembler.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698