v8/test
Igor Sheludko 3593ee832c Reland "[csa] Fix semantics of PopAndReturn"
This is a reland of 5e5eaf7954

This CL fixes the "function returns address of local variable" issue
which GCC was complaining about by using inline assembly instead of
address of a local for getting stack pointer approximation.

Original change's description:
> [csa] Fix semantics of PopAndReturn
>
> This CL prohibits using PopAndReturn from the builtins that
> have calling convention with arguments on the stack.
>
> This CL also updates the PopAndReturn tests so that even off-by-one
> errors in the number of poped arguments are caught which was not the
> case before.
>
> Motivation:
>
> PopAndReturn is supposed to be using ONLY in CSA/Torque builtins for
> dropping ALL JS arguments that are currently located on the stack.
> Disallowing PopAndReturn in builtins with stack arguments simplifies
> semantics of this instruction because in case of presence of declared
> stack parameters it's impossible to distinguish the following cases:
> 1) stack parameter is included in JS arguments (and therefore it will
>    be dropped as a part of 'pop' number of arguments),
> 2) stack parameter is NOT included in JS arguments (and therefore it
>    should be dropped in ADDITION to the 'pop' number of arguments).
>
> This issue wasn't noticed before because builtins with stack parameters
> relied on adapter frames machinery to ensure that the expected
> parameters are present on the stack, but on the same time the adapter
> frame tearing down code was effectively recovering the stack pointer
> potentially broken by the CSA builtin.
>
> Once we get rid of the arguments adapter frames keeping stack pointer
> in a valid state becomes crucial.
>
> Bug: v8:5269, v8:10201
> Change-Id: Id3ea9730bb0d41d17999c73136c4dfada374a822
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2460819
> Commit-Queue: Igor Sheludko <ishell@chromium.org>
> Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#70454}

Tbr: tebbi@chromium.org
Bug: v8:5269
Bug: v8:10201
Change-Id: Ic1a05fcc4efd2068538bff28189545cfd2617d9b
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2465839
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#70483}
2020-10-13 14:35:59 +00:00
..
benchmarks [test] Skip some slow benchmarks 2020-09-14 08:43:44 +00:00
cctest Reland "[csa] Fix semantics of PopAndReturn" 2020-10-13 14:35:59 +00:00
common [wasm][memory64] Enforce i64 index on i64 memory 2020-10-13 10:02:24 +00:00
debugger [debug] consider Object.keys free of side effects 2020-10-01 10:40:02 +00:00
debugging [Py3] Fix flake8 warnings 2020-07-10 16:57:15 +00:00
fuzzer [wasm][fuzzer] Fix data race when setting flags 2020-10-05 16:31:11 +00:00
fuzzilli Fix unhandled promise rejections in REPRL mode 2020-09-30 13:34:23 +00:00
inspector [wasm] Fix Liftoff stack check inspection 2020-10-13 12:20:04 +00:00
intl [intl] Fix timezone bug in test 2020-10-05 14:41:51 +00:00
js-perf-test [super property speed] Invert benchmark graphs 2020-08-31 09:24:46 +00:00
memory Reland^4 "[serializer] Allocate during deserialization" 2020-10-07 08:15:50 +00:00
message [wasm][memory64] Prepare memory tracing for i64 addresses 2020-10-13 11:41:54 +00:00
mjsunit [wasm] Add missing checks for growing the stack 2020-10-13 12:35:14 +00:00
mkgrokdump [heap] Move BaseSpace into base-space.h 2020-06-19 09:38:24 +00:00
mozilla [Respect] Prefer inclusive terms 2020-06-22 18:11:23 +00:00
test262 Reland "[intl] Impl ECMA402 PR 471 rounding behavior" 2020-10-02 00:14:46 +00:00
torque Reland "[torque] typed context slot access" 2020-08-06 11:32:38 +00:00
unittests [test] Suppress subobject-linkage warnings 2020-10-13 14:18:49 +00:00
wasm-api-tests wasm/c-api: fix the index of StackTraceFrame 2020-10-13 07:34:26 +00:00
wasm-js [wasm] Update spec tests 2020-10-09 17:51:14 +00:00
wasm-spec-tests [wasm] Update spec tests 2020-10-09 17:51:14 +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