Commit 1e928e90 authored by Jakob Gruber's avatar Jakob Gruber Committed by Commit Bot

Revert "Add boolean runtime checks for different element kinds."

This reverts commit 29308cf0.

Reason for revert: Use existing runtime functions instead

Original change's description:
> Add boolean runtime checks for different element kinds.
> 
> This will be used for Array.p.sort benchmarks to ensure that the
> arrays will have the correct element kind.
> 
> R=​cbruni@chromium.org, jgruber@chromium.org
> 
> Bug: v8:7382
> Change-Id: I4fe58d97d7f18fd193d4432964cf6b4f5335e0e7
> Reviewed-on: https://chromium-review.googlesource.com/1004754
> Commit-Queue: Jakob Gruber <jgruber@chromium.org>
> Reviewed-by: Jakob Gruber <jgruber@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#52511}

TBR=cbruni@chromium.org,jgruber@chromium.org,szuend@google.com

Change-Id: I45742879d3637470752335772f294d7e8ff3ce35
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:7382
Reviewed-on: https://chromium-review.googlesource.com/1004589Reviewed-by: 's avatarJakob Gruber <jgruber@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52513}
parent b69eeeed
......@@ -874,24 +874,6 @@ RUNTIME_FUNCTION(Runtime_HasFastPackedElements) {
IsFastPackedElementsKind(obj->map()->elements_kind()));
}
#define RUNTIME_FUNCTION_CHECK_ELEMENT_KIND(Name, Kind) \
RUNTIME_FUNCTION(Runtime_##Name) { \
SealHandleScope shs(isolate); \
DCHECK_EQ(1, args.length()); \
CONVERT_ARG_CHECKED(HeapObject, obj, 0); \
return isolate->heap()->ToBoolean(obj->map()->elements_kind() == Kind); \
}
RUNTIME_FUNCTION_CHECK_ELEMENT_KIND(HasPackedSmiElements, PACKED_SMI_ELEMENTS)
RUNTIME_FUNCTION_CHECK_ELEMENT_KIND(HasPackedDoubleElements,
PACKED_DOUBLE_ELEMENTS)
RUNTIME_FUNCTION_CHECK_ELEMENT_KIND(HasPackedObjectElements, PACKED_ELEMENTS)
RUNTIME_FUNCTION_CHECK_ELEMENT_KIND(HasHoleySmiElements, HOLEY_SMI_ELEMENTS)
RUNTIME_FUNCTION_CHECK_ELEMENT_KIND(HasHoleyDoubleElements,
HOLEY_DOUBLE_ELEMENTS)
RUNTIME_FUNCTION_CHECK_ELEMENT_KIND(HasHoleyObjectElements, HOLEY_ELEMENTS)
#undef RUNTIME_FUNCTION_CHECK_ELEMENT_KIND
RUNTIME_FUNCTION(Runtime_ValueOf) {
SealHandleScope shs(isolate);
......
......@@ -382,12 +382,6 @@ namespace internal {
F(GetOwnPropertyKeys, 2, 1) \
F(GetProperty, 2, 1) \
F(GetPrototype, 1, 1) \
F(HasPackedSmiElements, 1, 1) \
F(HasPackedDoubleElements, 1, 1) \
F(HasPackedObjectElements, 1, 1) \
F(HasHoleySmiElements, 1, 1) \
F(HasHoleyDoubleElements, 1, 1) \
F(HasHoleyObjectElements, 1, 1) \
F(HasFastPackedElements, 1, 1) \
F(HasInPrototypeChain, 2, 1) \
F(HasProperty, 2, 1) \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment