• Seth Brenith's avatar
    [torque] Automatically generate verifier functions · e483fb27
    Seth Brenith authored
    This change generates functions that verify the things that Torque knows
    about objects and their fields. We still must implement each verifier
    function in objects-debug.cc, but we can call into the generated code to
    verify that field types match their Torque definitions. If no additional
    verification is required, we can use the macro USE_TORQUE_VERIFIER as a
    shorthand for a verifier that calls the corresponding generated
    function.
    
    A new annotation @noVerifier can be applied to both class and field
    definitions, to prevent generating verification code. This allows fully
    customized verification for complicated cases like
    JSFunction::prototype_or_initial_map, which might not exist at all, and
    JSObject::elements, which might be a one pointer filler map.
    
    Because Factory::InitializeJSObjectFromMap fills new objects with
    undefined values, and many verifiers need to deal with partially-
    initialized objects, the generated verifiers allow undefined values on
    every class deriving from JSObject. In cases where stricter checks were
    previously performed, they are kept in objects-debug.cc.
    
    Bug: v8:7793
    Change-Id: I84034efadca89ba0aceddf92e886ffbfaa4c23fa
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1594042
    Commit-Queue: Seth Brenith <seth.brenith@microsoft.com>
    Reviewed-by: 's avatarSigurd Schneider <sigurds@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#61422}
    e483fb27
Name
Last commit
Last update
..
ls Loading commit data...
ast.h Loading commit data...
cfg.cc Loading commit data...
cfg.h Loading commit data...
constants.h Loading commit data...
contextual.h Loading commit data...
csa-generator.cc Loading commit data...
csa-generator.h Loading commit data...
declarable.cc Loading commit data...
declarable.h Loading commit data...
declaration-visitor.cc Loading commit data...
declaration-visitor.h Loading commit data...
declarations.cc Loading commit data...
declarations.h Loading commit data...
earley-parser.cc Loading commit data...
earley-parser.h Loading commit data...
global-context.h Loading commit data...
implementation-visitor.cc Loading commit data...
implementation-visitor.h Loading commit data...
instructions.cc Loading commit data...
instructions.h Loading commit data...
parameter-difference.h Loading commit data...
server-data.cc Loading commit data...
server-data.h Loading commit data...
source-positions.cc Loading commit data...
source-positions.h Loading commit data...
torque-compiler.cc Loading commit data...
torque-compiler.h Loading commit data...
torque-parser.cc Loading commit data...
torque-parser.h Loading commit data...
torque.cc Loading commit data...
type-oracle.cc Loading commit data...
type-oracle.h Loading commit data...
type-visitor.cc Loading commit data...
type-visitor.h Loading commit data...
types.cc Loading commit data...
types.h Loading commit data...
utils.cc Loading commit data...
utils.h Loading commit data...