Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8310558

[Lilliput/JDK17] Missing klass gap initialization in ContiguousSpace::allocate_temporary_filler

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • None
    • repo-lilliput-17
    • hotspot
    • None

      This is Lilliput JDK 17 specific, later versions have JDK-8278568 refactoring.

      We have missed the `set_klass_gap(0)` line in the patch here:

      ```
          } else {
            assert(size == CollectedHeap::min_fill_size(),
                   "size for smallest fake object doesn't match");
            instanceOop obj = (instanceOop) cast_to_oop(allocate(size));
      - obj->set_mark(markWord::prototype());
      - obj->set_klass_gap(0);
      - obj->set_klass(vmClasses::Object_klass());
      + if (UseCompactObjectHeaders) {
      + obj->set_mark(vmClasses::Object_klass()->prototype_header());
      + } else {
      + obj->set_mark(markWord::prototype());
      + obj->set_klass(vmClasses::Object_klass());
      + }
          }
        }
      ```

            shade Aleksey Shipilev
            shade Aleksey Shipilev
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: