1. 30 Sep, 2021 1 commit
    • Seth Brenith's avatar
      Reland "[torque] Get rid of @noVerifier annotation" · 07d82db1
      Seth Brenith authored
      This is a reland of 94958172
      
      Original change's description:
      > [torque] Get rid of @noVerifier annotation
      >
      > As one small step toward reducing annotations, I propose that all
      > classes get generated verifiers unless they've opted out of C++ class
      > generation via @doNotGenerateCppClass, and that generated verifiers
      > always verify every Torque-defined field. If a generated verifier is
      > incorrect, such as for JSFunction or DataHandler, we can just avoid
      > calling it and hand-code the verification.
      >
      > Bug: v8:7793
      > Change-Id: I7c0edb660574d0c688a59c7e90c41ee7ad464b42
      > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3171758
      > Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
      > Commit-Queue: Seth Brenith <seth.brenith@microsoft.com>
      > Cr-Commit-Position: refs/heads/main@{#77145}
      
      Bug: v8:7793
      Change-Id: I3da34705bf9fc2b1886161f8f59c7275583f7fc4
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3194812
      Commit-Queue: Seth Brenith <seth.brenith@microsoft.com>
      Reviewed-by: 's avatarNico Hartmann <nicohartmann@chromium.org>
      Cr-Commit-Position: refs/heads/main@{#77168}
      07d82db1
  2. 29 Sep, 2021 3 commits
  3. 30 Aug, 2021 1 commit
  4. 21 Jul, 2021 1 commit
  5. 25 Jun, 2021 1 commit
    • Mythri A's avatar
      [objects] Fix torque definition of JSFunction · 26ebc4f7
      Mythri A authored
      The code and prototype_or_initial_map fields are marked as weak in the
      torque definition of JSFunction. Given we don't have any annotations
      that generate BodyDescriptors or the C++ class specifying weak there
      didn't reflect in the actual C++ implementation.
      
      In the C++ implementation we were treating those as strong pointers
      and the rest of the code also expects them as strong pointers and
      doesn't actually deal with cleared weak references.
      
      Since JSFunction's header doesn't have any weak references we can just
      fallback to JSObject::BodyDescriptor that iterates through all header
      fields and the other JSObject fields as strong pointers. This is what
      was happening because JSFunction didn't have a body descriptor and
      we were falling back to JSObject::BodyDescriptor
      
      So this is a clean up CL to avoid confusion. There shouldn't be
      any change in behaviour.
      
      So this CL basically:
      1. Drops weak from the torque definition to match with implementation
      2. Changes JSFunction::BodyDescriptor to JSObject::BodyDescriptor when
      iterating over objects to be consistent with other JSObjects with
      strong pointers.
      
      Change-Id: I7c3e49f1759164a0f2517b3d5b8d0e5169b025ff
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2987827Reviewed-by: 's avatarNico Hartmann <nicohartmann@chromium.org>
      Reviewed-by: 's avatarGeorg Neis <neis@chromium.org>
      Commit-Queue: Mythri Alle <mythria@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#75387}
      26ebc4f7
  6. 17 Jun, 2021 1 commit
  7. 17 Dec, 2020 1 commit
  8. 28 Oct, 2020 1 commit
    • Tobias Tebbi's avatar
      [torque] generate C++ class definitions per Torque file · 03f60296
      Tobias Tebbi authored
      This CL splits the class definitions per .tq file, to realize the
      following relationship:
      A class defined in src/objects/foo.tq has a C++ definition in
      src/objects/foo.h. Torque then generates:
      
      - torque-generated/src/objects/foo-tq.inc
        An include file (no proper header) to be included in src/objects/foo.h
        containing the Torque-generated C++ class definition.
      
      - torque-generated/src/objects/foo-tq-inl.inc
        An include file (no proper header) to be included in
        src/objects/foo-inl.h containing inline function definitions.
      
      - torque-generated/src/objects/foo-tq.cc
        A source file including src/objects/foo-inl.h that contains non-inline
        function definitions.
      
      Advantages of this approach:
      - Avoid big monolithic headers and preserve the work that went into
        splitting objects.h
      - Moving a definition to Torque keeps everything in the same place
        from a C++ viewpoint, including a fully Torque-generated C++ class
        definition.
      - The Torque-generated include files do not need to be independent
        headers, necessary includes or forward declarations can just be added
        to the headers that include them.
      
      Drive-by changes:
      A bunch of definitions and files had to be moved or created to realize
      a consistent 1:1 relationship between .tq files and C++ headers.
      
      
      Bug: v8:7793
      TBR: hpayer@chromium.org
      Change-Id: I239a89a16d0bc856a8669d7c92aeafe24a7c7663
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2470571
      Commit-Queue: Tobias Tebbi <tebbi@chromium.org>
      Reviewed-by: 's avatarNico Hartmann <nicohartmann@chromium.org>
      Reviewed-by: 's avatarSeth Brenith <seth.brenith@microsoft.com>
      Cr-Commit-Position: refs/heads/master@{#70853}
      03f60296