void ensureCapacityForBytes(final long offset, final long numBytes) {
    // Do not increase the memory capacity if no bytes are being written
    // regardless of what the address may be.
    if (numBytes == 0) {
      return;
    }
    final long lastByteIndex = Math.addExact(offset, numBytes);
    final long lastWordRequired = ((lastByteIndex - 1) / Bytes32.SIZE);
    maybeExpandCapacity((int) lastWordRequired + 1);
  }
Expands the active words to accommodate the specified byte position.

@param offset The location in memory to start with.
@param numBytes The number of bytes to get.
evm/src/main/java/org/hyperledger/besu/evm/frame/Memory.java