Uploaded image for project: 'Code Tools'
  1. Code Tools
  2. CODETOOLS-7903912

JMH: Pad using a mix of bytes and longs

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Unresolved
    • Icon: P4 P4
    • None
    • None
    • tools
    • None
    • jmh

      Padding needs to be done in a way that avoids leaving gaps in the object layout. Current strategy lays out 256 byte fields, which then becomes a significant part of generated code. To reduce code we could consider padding using a mix of byte and long fields.

      A PoC which assumes 16 bytes + 240 bytes in longs would be sufficient reduces generated JMH code size (both compiled and source) by ~20%.

      This might be of interest in light of JDK-8345302

            redestad Claes Redestad
            redestad Claes Redestad
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: