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

Issue 2270743003: Get rid of PropagateScopeInfo, update asm_function in set_asm_module instead. (Closed)

Created:
4 years, 4 months ago by Toon Verwaest
Modified:
4 years, 3 months ago
Reviewers:
titzer
CC:
v8-reviews_googlegroups.com, bradnelson
Base URL:
https://chromium.googlesource.com/v8/v8.git@master
Target Ref:
refs/pending/heads/master
Project:
v8
Visibility:
Public.

Description

Get rid of PropagateScopeInfo, update asm_function in set_asm_module instead. The last user was propagating asm_module_ to inner function scopes as asm_function_. asm_function_ is already set upon scope creation when the outer scope IsAsmModule(). With default parameter it's possible that inner scopes are created before set_asm_module() is called. To keep current behavior we'll eagerly mark inner scopes as asm_function_ upon set_asm_module(). There's only one special case that used to be marked asm_function_ which is now no longer marked as such: asm functions in block scopes that are 'Finalized'. PropagateScopeInfo used to mark them as asm_function_ as well, whereas the new version would not mark them upon construction of the inner scope. I presume both above cornercases aren't actually intended valid asm.js use-cases anyway. The second we can now easily identify in the verifier and mark as invalid asm, since we'll have an asm module with non-asm-function inner functions. If we want to disallow the first, we can also not mark them as asm_functions_ (by removing the loop I added in set_asm_module), which will reveal this structure to the validator. BUG=v8:5209 Committed: https://crrev.com/ce9e773828fdd946eee243c1229f914b548df82c Cr-Commit-Position: refs/heads/master@{#39039}

Patch Set 1 #

Total comments: 3

Patch Set 2 : Move set_asm_module to scopes.cc #

Patch Set 3 : rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+11 lines, -19 lines) Patch
M src/ast/scopes.h View 1 2 2 chunks +1 line, -4 lines 0 comments Download
M src/ast/scopes.cc View 1 2 5 chunks +10 lines, -15 lines 0 comments Download

Messages

Total messages: 12 (4 generated)
Toon Verwaest
ptal
4 years, 4 months ago (2016-08-23 12:43:42 UTC) #2
titzer
https://codereview.chromium.org/2270743003/diff/1/src/ast/scopes.h File src/ast/scopes.h (right): https://codereview.chromium.org/2270743003/diff/1/src/ast/scopes.h#newcode684 src/ast/scopes.h:684: void set_asm_module() { Move to cc file? Not performance ...
4 years, 4 months ago (2016-08-23 13:08:59 UTC) #3
Toon Verwaest
Addressed comment. https://codereview.chromium.org/2270743003/diff/1/src/ast/scopes.h File src/ast/scopes.h (right): https://codereview.chromium.org/2270743003/diff/1/src/ast/scopes.h#newcode687 src/ast/scopes.h:687: for (Scope* inner = inner_scope_; inner != ...
4 years, 4 months ago (2016-08-23 13:17:51 UTC) #4
Toon Verwaest
ping
4 years, 3 months ago (2016-08-31 08:51:03 UTC) #5
titzer
lgtm
4 years, 3 months ago (2016-08-31 08:51:54 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2270743003/40001
4 years, 3 months ago (2016-08-31 09:01:35 UTC) #9
commit-bot: I haz the power
Committed patchset #3 (id:40001)
4 years, 3 months ago (2016-08-31 09:35:58 UTC) #10
commit-bot: I haz the power
4 years, 3 months ago (2016-08-31 09:36:25 UTC) #12
Message was sent while issue was closed.
Patchset 3 (id:??) landed as
https://crrev.com/ce9e773828fdd946eee243c1229f914b548df82c
Cr-Commit-Position: refs/heads/master@{#39039}

Powered by Google App Engine
This is Rietveld 408576698