Home / Function/ performHeapAllocation() — netty Function Reference

performHeapAllocation() — netty Function Reference

Architecture documentation for the performHeapAllocation() function in ByteBufAllocatorAllocPatternBenchmark.java from the netty codebase.

Function java Buffer Telemetry calls 3 called by 2

Entity Profile

Dependency Diagram

graph TD
  26bf866c_3b1b_fbfe_7ea6_9d3c0dcb9920["performHeapAllocation()"]
  2b9d2c55_b3ab_2241_3c94_2c28d1742399["AllocationPatternState"]
  26bf866c_3b1b_fbfe_7ea6_9d3c0dcb9920 -->|defined in| 2b9d2c55_b3ab_2241_3c94_2c28d1742399
  08c39d59_9fc8_19d0_9a47_4c56e7a2655c["setupAllocatorAndPollute()"]
  08c39d59_9fc8_19d0_9a47_4c56e7a2655c -->|calls| 26bf866c_3b1b_fbfe_7ea6_9d3c0dcb9920
  f3d1b2b3_f386_f527_48d5_e70dc0e65156["heapAllocation()"]
  f3d1b2b3_f386_f527_48d5_e70dc0e65156 -->|calls| 26bf866c_3b1b_fbfe_7ea6_9d3c0dcb9920
  eb3b24cc_32a0_7289_8880_2dc69bc0b4b8["getNextSizeIndex()"]
  26bf866c_3b1b_fbfe_7ea6_9d3c0dcb9920 -->|calls| eb3b24cc_32a0_7289_8880_2dc69bc0b4b8
  bbe06704_584b_9c24_dc13_4fce32d179d4["getNextReleaseIndex()"]
  26bf866c_3b1b_fbfe_7ea6_9d3c0dcb9920 -->|calls| bbe06704_584b_9c24_dc13_4fce32d179d4
  d17baac7_a97f_d30f_97ad_c7dad906b64b["release()"]
  26bf866c_3b1b_fbfe_7ea6_9d3c0dcb9920 -->|calls| d17baac7_a97f_d30f_97ad_c7dad906b64b
  style 26bf866c_3b1b_fbfe_7ea6_9d3c0dcb9920 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

microbench/src/main/java/io/netty/microbench/buffer/ByteBufAllocatorAllocPatternBenchmark.java lines 145–155

        @CompilerControl(CompilerControl.Mode.DONT_INLINE)
        public void performHeapAllocation() {
            int size = sizes[getNextSizeIndex()];
            int releaseIndex = getNextReleaseIndex();
            ByteBuf oldBuf = buffers[releaseIndex];
            if (oldBuf != null) {
                release(oldBuf);
            }
            ByteBuf newBuf = allocateHeap(allocator, size);
            buffers[releaseIndex] = newBuf;
        }

Domain

Subdomains

Frequently Asked Questions

What does performHeapAllocation() do?
performHeapAllocation() is a function in the netty codebase, defined in microbench/src/main/java/io/netty/microbench/buffer/ByteBufAllocatorAllocPatternBenchmark.java.
Where is performHeapAllocation() defined?
performHeapAllocation() is defined in microbench/src/main/java/io/netty/microbench/buffer/ByteBufAllocatorAllocPatternBenchmark.java at line 145.
What does performHeapAllocation() call?
performHeapAllocation() calls 3 function(s): getNextReleaseIndex, getNextSizeIndex, release.
What calls performHeapAllocation()?
performHeapAllocation() is called by 2 function(s): heapAllocation, setupAllocatorAndPollute.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free