v8/test
Jakob Gruber 76a2ab06a1 [compiler] Direct heap reads for JSArrayRef
There are two aspects to the non-JSObject parts of JSArrayRef:

- JSArrayRef::length. Relevant only in two spots, 1. when reading
(immutable) array boilerplates and 2. for GetOwnCowElement.

- JSArrayRef::GetOwnCowElement. May read into a copy-on-write backing
store. Relies on the invariant that cow backing stores are immutable.

This CL renames the length accessor to length_unsafe to make the
danger explicit at callsites.

For GetOwnCowElement the refactor is slightly larger, since we now
need to read into the backing store while keeping full control of
object reads (e.g. JSArray::length and JSArray::elements_kind). We
make all reads explicit at the call site by requiring that elements,
elements kind, and length are passed in as arguments to
GetOwnCowElement. Inside GetOwnCowElement, consistency between these
is *not* guaranteed due to concurrency. At runtime, consistency *is*
guaranteed through the reference-equality check on the elements seen
during compilation. The actual elements read is implemented in
ConcurrentLookupIterator::GetOwnCowElement.

Bug: v8:7790
Change-Id: I9aa169ce4f2b1e2bfe1e9232007669eb7654a995
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2695403
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Georg Neis <neis@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72834}
2021-02-18 08:08:08 +00:00
..
benchmarks IWYU: Added missing include: include/cppgc/persistent.h 2021-02-17 17:37:29 +00:00
cctest [compiler] Direct heap reads for JSArrayRef 2021-02-18 08:08:08 +00:00
common [wasm][eh] Update catch_all encoding 2021-02-17 12:42:49 +00:00
debugger [wasm][eh] Update catch_all encoding 2021-02-17 12:42:49 +00:00
debugging [wasm] [debugging] Fix --wasm-gdb-remote 2020-12-08 19:37:25 +00:00
fuzzer [wasm] Support EH in the compile fuzzer 2021-02-17 15:30:51 +00:00
fuzzilli Fix unhandled promise rejections in REPRL mode 2020-09-30 13:34:23 +00:00
inspector [debug][inspector] Use first rather than closest break location. 2021-02-17 14:02:49 +00:00
intl [test] Disable tests failing with new msan roll 2021-02-12 11:53:48 +00:00
js-perf-test [super] Rewrite perf tests 2020-11-16 08:36:24 +00:00
memory Reland^4 "[serializer] Allocate during deserialization" 2020-10-07 08:15:50 +00:00
message PPC: skip all Simd tests on PPC 2021-02-16 19:52:35 +00:00
mjsunit Reland "[interpreter] Short Star bytecode" 2021-02-17 16:18:26 +00:00
mkgrokdump Replace libc functions with base wrappers 2020-11-17 08:50:41 +00:00
mozilla [compiler, infra] Add a --stress-concurrent-inlining flag and a bot 2021-01-29 12:05:03 +00:00
test262 [test] Disable tests failing with new msan roll 2021-02-12 11:53:48 +00:00
torque [torque] Allow returning pairs from builtins 2021-01-19 18:03:12 +00:00
unittests cppgc: Implement process-global state accessors. 2021-02-17 22:37:24 +00:00
wasm-api-tests [test][cleanup] Rename WASM_*_GLOBAL to WASM_GLOBAL_* 2020-12-17 21:26:54 +00:00
wasm-js [wasm][memory64] Update spec tests 2021-02-08 13:17:29 +00:00
wasm-spec-tests [wasm-simd] Add a decode failure if hardware does not support SIMD 2021-02-12 01:28:54 +00:00
webkit Disallow \8 and \9 in strict mode and template literals 2020-08-03 18:05:14 +00:00
BUILD.gn [turbofan] Make OSR and stack slots compatible 2020-10-05 17:41:02 +00:00
OWNERS Use relative paths to OWNERS files 2019-08-12 13:52:52 +00:00