Remove SMI length check from Builtins::Generate_ArrayIndexOf
Currently, Generate_ArrayIndexOf handles the hypothetical case of an array with a fast ElementsKind and non-SMI length. This should not happen (and is checked against in JSArray::JSArrayVerify of objects_debug.cc). Therefore this CL replaces that handling with a CSA_ASSERT that the length is indeed SMI. The CL also simplifies loading of the (SMI) length on 64 bit architectures by using LoadAndUntagObjectField instead of LoadObjectField+SmiToWord. The CL does not add new tests, because test/mjsunit/array-length.js should cover this already. BUG=v8:5985 Review-Url: https://codereview.chromium.org/2714173002 Cr-Commit-Position: refs/heads/master@{#43431}
Showing
Please
register
or
sign in
to comment