// We found an existing child, skip over that.
offset = existingChild.getOffset().add(existingChild.getSize());
// Align the new offset
if (!offset.toWord().and(alignMask).isZero()) {
offset = offset.toWord().add(alignMask).and(alignMask.not()).toOffset();
}
// Do we have space left?
if (offset.toWord().add(size).GT(this.size.toWord())) {
throw new ResourceNotFreeException();