private void discardFromCtxBruteForce(Arena arena, DiscardContext ctx, int freeListIx) {
    // Discard all the locked blocks.
    discardAllBuffersFromCtx(arena, ctx);
    // Finalize the headers.
    for (int baseIx = ctx.baseCount - 1; baseIx >= 0; --baseIx) {
      finalizeDiscardResult(arena, ctx, freeListIx, ctx.baseHeaders[baseIx]);
    }
  }
Frees up memory by deallocating based on base and victim buffers in MoveContext.
@param freeListIx The list for which the blocks are being merged.
llap-server/src/java/org/apache/hadoop/hive/llap/cache/BuddyAllocator.java