Manuscript Offprint
arXiv:2611.07707CAMP: Context-Aware Mapping and Placement for LLMs on 3D-IMC Arrays
Orhun Görkem
IBM Research
Rüschlikon, Switzerland
Athanasios Vasilopoulos
IBM Research
Rüschlikon, Switzerland
Georgios Pagonis
IBM Research
Rüschlikon, Switzerland
Victoria Clerico
IBM Research
Rüschlikon, Switzerland
Victoria.Clerico.Da.Costa@ibm.com
Hadjer Benmeziane
IBM Research
Rüschlikon, Switzerland
Irem Boybat
IBM Research
Rüschlikon, Switzerland
Hsinyu Tsai
IBM Research
San Jose, CA, USA
Abu Sebastian
IBM Research
Rüschlikon, Switzerland
William Andrew Simon
IBM Research
Rüschlikon, Switzerland
Abstract
Large Language Models (LLMs) incur severe memory-access overheads due to the cost of loading large weight matrices and Key-Value (KV) caches. Analog In-Memory Computing (AIMC) is an emerging solution that enables computation directly on static weights stored in memory, substantially reducing energy and latency. 3D-IMC further stacks memory arrays into vertical tiers, increasing capacity but revealing a new challenge: how weights are placed in memory determines which Matrix-Vector Multiplications (MVMs) can execute concurrently, affecting latency and throughput. The concurrency aspect of 3D-IMC weight-mapping remains underexplored in the literature, leading to sub-optimal utilization of compute resources on 3D-IMC chips.
In this context we propose Context-Aware Mapping and Placement (CAMP), an inference-context-aware weight mapping algorithm for 3D-IMC-based LLM accelerators. CAMP captures the potential resource contention resulting from the architecture, targeted network, and runtime context in a conflict matrix, enabling throughput-optimized weight mapping. This mapping is refined through a profiling-driven feedback loop that efficiently prunes the search space and returns optimized mappings within practical runtimes. CAMP is an offline, software-based solution requiring no hardware changes and improving 3D-IMC compute utilization from 42.4% to 60.3%, delivering up to 2.0× higher 3D-IMC throughput and 1.74× higher end-to-end throughput over state-of-the-art mapping algorithms.
CCS Concepts: • Computer systems organization → Heterogeneous (hybrid) systems; Parallel architectures; • Hardware → Emerging architectures.
Keywords: In-memory computing; LLM inference; batch-parallelism; weight mapping; 3D-IMC
1 Introduction
Large Language Models (LLMs) have recently demonstrated remarkable capabilities across natural language processing and beyond [27], making them widely adopted in industry and everyday life. Serving LLMs efficiently is therefore an important but challenging goal, made harder by growing parameter counts [24, 27, 44].
The mainstream hardware for LLM inference is the Graphics Processing Unit (GPU). While well suited to the compute-heavy prefill phase, GPU compute resources are underutilized during the memory-bound decode phase [15, 22, 24], where limited memory bandwidth results in Key-Value (KV) cache and weight loading dominating inference time. Prior works target the KV-loading bottleneck via software techniques such as KV compression [38, 45, 48], new models such as State-Space Models (SSMs) [11], or memory-centric hardware such as Dynamic Random-Access Memory (DRAM)-based Processing-In-Memory (PIM) [12, 22, 32, 46]. Meanwhile, the weight loading bottleneck can be mitigated with sparsity and quantization [13, 26], or eliminated altogether via Non-Volatile Memory (NVM)-based Analog In-Memory Computing (AIMC) accelerators [3–5, 9, 25, 41].
AIMC accelerators eliminate weight movement by executing Matrix-Vector Multiplications (MVMs) involving static weights directly within the memory array. However, NVM's poor write and endurance characteristics [19] require all network weights to fit on-chip. As model size grows, this constraint has encouraged research into 3D AIMC devices, whose memory arrays consist of vertically stacked tiers, enabling high storage density [5, 9, 25, 41].
An open-source script for simulations can be found at https://anonymous.4open.science/r/3DIMC_CM_Mapping-904D/.
Orhun Görkem, Athanasios Vasilopoulos, Georgios Pagonis, Victoria Clerico, Hadjer Benmeziane, Irem Boybat, Hsinyu Tsai, Abu Sebastian, and William Andrew Simon

Figure 1. (a) Static weights may be mapped to improve the latency of an individual MVM (TP) or enable MVMs to execute concurrently (BP). (b) Existing algorithms always maximize TP agnostically to inference context. (c) In contrast, CAMP maps in a context-aware manner by first encoding the context in a conflict matrix. (d) A refinement loop converges to a mapping with an optimized balance of TP, BP, and EP, (e) improving runtime efficiency via better utilization of 3D-IMC compute resources.
While 3D AIMC (3D-IMC) increases storage capacity via vertical integration, compute capability remains static, as multiple tiers within the same array cannot be accessed simultaneously. This limitation creates a trade-off between prioritizing single-MVM latency and enabling inter-MVM concurrency, which can be tuned through the weight mapping as illustrated in Figure 1a. Weight mapping determines the degree of Tensor Parallelism (TP) by fixing how many compute resources are allocated to a single MVM, tuning its latency. It also determines the degree of Batch Parallelism (BP), the ability of the accelerator to process multiple tokens within a batch concurrently by assigning MVMs to disjoint resources and enabling inter-token computation overlap. Finally, for Mixture-of-Experts (MoE) models, weight mapping defines Expert Parallelism (EP), or how compute resources are allocated to experts within an MoE layer.
Although optimized weight mapping benefits runtime performance due to better compute utilization, optimizing 3D-IMC weight mapping is challenging:
Optimizing individual parallelism dimensions by finding a mapping that maximizes even a single form of parallelism is difficult due to varying LLM workload structures, runtime contexts, and accelerator architectures.
Balancing parallelism across the TP, BP, and EP paradigms is another challenge, as optimizing one form of parallelism can directly constrain the others [16]. For example, increasing TP allocates more resources to a single MVM, reducing available resources for concurrently executing other MVMs and thereby limiting BP. Similarly, increasing EP concentrates resources in experts, allowing experts to run concurrently but reducing availability to other MVMs.
Robustness across inference contexts consisting of system architectures, varying workloads, and expected runtime contexts is necessary to develop a generally applicable performant mapping solution.
Finally, mapping-space complexity precludes exhaustive search due to the enormous weight mapping search space, which grows rapidly with the number of MVMs to be mapped and the number of available resource configurations along both the planar and vertical dimensions. State-of-the-art mapping methods [3, 5] overcome this by greedy mapping procedures only maximizing TP, at the expense of BP, EP, and robustness against varying inference contexts.
To address these challenges, we propose Context-Aware Mapping and Placement (CAMP), an inference-context-aware mapping algorithm for 3D-IMC-based LLM accelerators. Figure 1 provides an overview of CAMP. CAMP addresses the challenges of weight mapping as follows:
(1) First, a profiling phase analyzes the workload under the expected inference context — the system architecture, target LLM, and runtime context — and encodes the probability of resource conflicts between pairs of static MVMs into a conflict matrix. The mapping process then uses this matrix to adapt automatically and robustly to the given circumstances.
(2) Next, an initial mapping phase maps all static MVMs to the 3D-IMC accelerator, using the conflict matrix to map MVMs likely to contend for resources to disjoint resource groups, improving BP and EP.
(3) Finally, the mapping is refined via a profile-guided, feedback-driven pruned search, which utilizes the projected latency of varied candidate mappings to guide refinement toward operating points at which the balance between TP, BP, and EP is tuned for maximum resource utilization.
The exact planar and vertical weight placements are obtained efficiently through a proxy penalty computed from the conflict matrix, which prunes a large region of the search space. A beam search strategy trades solution optimality against optimization time, placing CAMP between a fully greedy heuristic and globally optimal methods, while yielding near-optimal mappings within acceptable runtimes.
The contributions of this paper are thus:
- We analyze how system architecture, LLM model, and runtime characteristics, collectively referred to as the inference context, impact runtime throughput and latency.
- We introduce the conflict matrix, a compact abstract representation that encodes the inference context in a single structure amenable to efficient optimization.
- We propose Context-Aware Mapping and Placement (CAMP), an inference-context-aware weight-mapping algorithm built on this abstraction, which first determines each weight tensor's placement shape and assignment to 3D-IMC, then refines placement via a pruned search over reshapings, guided by profiling-in-the-loop feedback.
- We demonstrate cross-regime adaptivity, as CAMP produces markedly different mappings across runtime contexts, networks, and hardware, minimizing latency at low batch sizes, maximizing throughput at high batch sizes, and natively enabling EP in MoE LLMs.
Thorough evaluations demonstrate up to 2.0× higher 3D-IMC runtime throughput, 1.74× higher end-to-end throughput, and a 42% increase in 3D-IMC compute utilization, validating CAMP's 3D-IMC weight mapping effectiveness.
2.1 Large Language Models
LLMs are state-of-the-art models across many domains and comprise transformer blocks, which employ the attention mechanism, capturing long-range inter-token dependencies [27], and Feed-Forward Network (FFN) layers that transform the learned token-level associations into higher-level representations. While LLMs' substantial representational capacity makes them extremely versatile, they also incur substantial compute and memory demands from their static and dynamic parameter counts.
2.2 Challenges in LLM execution
The effectiveness of the attention mechanism on long sequences stems from its ability to model dependencies between all token pairs [42]. However, the quadratic computational complexity of attention poses a major challenge for long-context inference. KV caching mitigates this issue by computing and caching keys and values for all tokens once (prefill) and reusing the stored values for each output token (decode), reducing per-token attention complexity from to [34].
While KV caching reduces decode-phase computation, cached values must be re-fetched from the memory for every generated token. Large weight parameter counts add further memory pressure, motivating memory-centric solutions to mitigate bandwidth limitations.

Figure 2. Each tier in an 3D-IMC memory array stores weights that are used to perform MVMs in-situ.
2.3 Reducing data movement via IMC
In- and near-memory computing paradigms have emerged as promising approaches to reduce the memory pressure imposed by large KV caches and static weights. Their key principle is to minimize expensive data transfers by performing computation closer to where data are stored or by exploiting high-bandwidth local interconnects.
On the attention side, one such approach is DRAM-based PIM [18, 28–30, 32, 46], alleviating the KV-cache access bottleneck by exploiting the internal bandwidth of DRAM and performing attention-related computation near KV storage.
A complementary approach addressing static weights is NVM-based AIMC accelerators, as illustrated in Figure 2. Such architectures represent model weights as analog states such as cell conductance and exploit analog device characteristics to perform massively parallel MVMs directly within memory arrays, eliminating weight movement [4, 5, 9, 19, 20, 25, 31, 33, 37, 43]. While AIMC's poor write and endurance characteristics [19] make it ill-suited to storing frequently changing data such as the KV cache, avoiding repeated static weight transfers allows AIMC accelerators to reduce inference latency and improve energy efficiency significantly. The different characteristics of KV cache and static weights have motivated interest in attention/static MVM disaggregation, in which attention operations and MVMs with static weights execute on separate specialized hardware [1, 28, 29, 46, 47].
For conciseness, we hereafter simply use the term MVM to refer to all MVMs with static weights accelerated with AIMC, specifically the Query-Key-Value (QKV), output, and the FFN Gated Up (G+U) and down projections. This is in contrast to MVMs with dynamic inputs occurring in the attention block and executed on the attention unit.
2.4 3D-IMC opportunities and challenges
As LLMs continue to grow in parameter count, increasing memory density has become necessary to accommodate their storage requirements. To address this capacity bottleneck, proposed three-dimensional AIMC (3D-IMC) architectures significantly increase the weight capacity of conventional AIMC architectures through the vertical integration of memory arrays [5, 10, 25, 36, 41].
Orhun Görkem, Athanasios Vasilopoulos, Georgios Pagonis, Victoria Clerico, Hadjer Benmeziane, Irem Boybat, Hsinyu Tsai, Abu Sebastian, and William Andrew Simon

Figure 3. Hierarchical H-tree architecture (a-e) [20, 36, 37]. Weight mapping options when leaf groups comprise 4 leaves (f-i).
However, because vertical tier-level parallelism cannot be implemented due to peripheral sharing and vertical interconnect bandwidth constraints, compute capacity scales only in the planar dimension in several popular 3D-memory paradigms such as NAND flash, a limitation referred to as the One-Tier-at-a-Time (OTT) constraint [3, 5].
This limitation requires thoughtful interconnect design to efficiently serve activations and gather outputs. A popular design that achieves these goals is a hierarchical H-tree [10, 20, 28, 46], illustrated in Figure 3(a-e). In such a design, the 3D-IMC architecture comprises an array of Leaf Groups (LGs), hereafter referred to as the 3D-IMC macro, interconnected by an H-tree topology [20, 36, 37]. This structure is preferred for its input-broadcasting and output-accumulation capabilities, enabling large MVMs to be parallelized across multiple LGs. Each LG is further composed of leaves, each containing vertically stacked AIMC tiles, as shown in Figure 3(e). Accumulation units within leaves and LGs facilitate output accumulation, enabling multiple leaves to contribute to the output of one MVM, a feature exploited in Section 3.1. Beyond the macro, the architecture provides a global IO buffer for intermediate vectors, a Digital Processing Unit (DPU) for activation functions, and a global controller. The accelerator is paired with an attention unit which performs the attention stage, including KV-cache loading, while the accelerator is responsible for the static MVMs.
3 Motivational study: Impact of weight mapping in 3D-IMC on runtime
This work is motivated by the following insights into how the process of mapping an individual MVM into the 3D-IMC macro impacts global throughput, and how the LLM inference context directly impacts the optimal choice of mapping.
3.1 Mapping weights to 3D-IMC tiles and tiers
The weights of MVMs are tiled before being mapped to 3D-IMC tiles. The tiling and activation-flow strategy is similar to that of [20]. As Figure 3(f-g) illustrates, the weight matrix is first split column-wise along the output dimension and then row-wise along the input dimension. The row split is chosen so that each block fills one leaf (four tiles).
Once an MVM's weights are tiled column- and row-wise, the tiled blocks in each column are placed on LGs as shown in Figure 3(h). All blocks of a column (shown with the same color in the figure) must reside on the same LG, since accumulation can only occur within an LG. Crucially, within an LG, the blocks of a column (different shades of the same color) can be mapped onto one or more leaves, e.g. 1, 2, or 4 leaves (or 4, 8, or 16 tiles) in macro configurations with 4 leaves per LG. We refer to the -leaf option as -way TP, because the number of mapped leaves determines the degree of TP for the corresponding MVM. Under the 1-way TP option, all blocks are vertically stacked on the same four tiles in a leaf. The 2- and 4-way TP options spread each block across more tiles, reducing vertical stacking along a column.
This flexibility enables trade-offs between vertical and planar mappings, as discussed in Section 3.2.
At runtime, the input activation is broadcast to the LGs holding the weights of the corresponding MVM. Within each LG, the input vector is scattered into chunks and routed to the relevant leaves depending on the chosen weight placement option. The resulting output vectors are accumulated within a leaf and across leaves for 2- and 4-leaf TP. Finally, the per-LG output vectors are transferred to the global IO buffer and concatenated. Figure 3(h-i) visualizes the process.
3.2 Single-MVM latency/batch-parallelism trade-off
A high degree of TP parallelizes the MVM across the tiled weight blocks by spreading the computation over planar resources, whereas lower TP options make more use of the vertical space. This choice has direct performance implications. As an example, Figure 1a visualizes the difference between 2-way and 4-way TP layouts. The vertical z-axis is the tier axis, while the 8 × 8 horizontal plane corresponds to the LGs. The 2-way TP option is marked as BP-friendly because it gives up a degree of TP to enable more BP: the FFN G+U MVM (yellow voxels) can overlap with the output-projection and FFN down-projection MVMs (green and purple voxels) across tokens, since they share no LGs. The advantage of 4-way TP is that it uses fewer vertical tiers per MVM, so less of the computation is serialized, giving shorter per-MVM latencies. The most suitable option should be chosen based on the targeted workload and expected runtime context.
3.3 Impact of inference context on TP degree
We find that the optimal selection of TP degree for individual MVMs is heavily influenced by the inference context, which can be broken down into three categories:
Architectural characteristics such as the tier count and planar space define available height and width for MVM shapes, while LG size defines valid TP degrees. Similarly, a low-bandwidth or coarse-grained off-chip interconnect between the 3D-IMC accelerator and the attention unit may induce synchronization between tokens in a batch before communication, limiting BP across different transformer layers. Consequently, favoring BP for weight mapping across layers provides little benefit, as the resulting computational parallelism cannot be effectively exploited.
Network characteristics such as network type and size also affect the trade-off between TP and BP, as larger networks place greater pressure on limited compute resources.
Deserving special mention here are MoE models, efficient alternatives to dense LLMs as input-specific expert routing enables sparse FFN computation [35]. 3D-IMC devices, with their skewed storage-to-compute capacity, naturally exploit MoE sparsity [5].
Mapping MoE LLMs onto 3D-IMC accelerators raises two challenges. First, MoEs introduce the concept of Expert Parallelism (EP), where sibling experts (expert alternatives of the

Figure 4. Impact of 3D-IMC mapping strategies on decode-step throughput for Llama 3.1-70B across representative runtime contexts. Results shown for a sequence length of 128.
same FFN) can be mapped such that they can run in mutually exclusive sets of IMC tiles in parallel. However, enabling EP comes at the expense of TP and BP, further complicating the optimization space. Second, the aggregate expert weights are larger than their dense counterparts even though only the top- experts are activated per layer. The compute constraints of 3D-IMC make it infeasible to place all sibling experts such that they execute concurrently. Mapping must therefore decide which experts to parallelize and which to initialize — a decision that can exploit domain-specific expert co-activation imbalances. The extent of these imbalances is discussed in Appendix B.
Runtime characteristics such as expected batch size and sequence length, further impact mapping. Single-batch, short-context inference is typical at the edge [6], where minimizing latency through high TP is preferred. In contrast, data centers typically serve large batches over long sequences, where maximizing batch-level overlap to achieve high throughput is more desirable.
3.4 Underutilization of the 3D-IMC accelerator
Existing 3D-IMC mapping algorithms [3, 5] are context-agnostic and maximize TP, underutilizing compute resources even at saturating batch sizes. Figure 1e shows that the context-agnostic method presented in [5] utilizes only 42% of the 3D-IMC compute capacity on average. Its objective minimizes the latency of each MVM in isolation and therefore provides no incentive to enable concurrent MVM execution across tokens in a batch.
Figure 4 illustrates the impact of weight mapping across inference contexts using three alternatives: a throughput-friendly mapping that promotes overlapped execution across tokens in a batch, a latency-friendly mapping that maximizes TP to minimize latency, and a balanced mapping. The throughput-friendly mapping improves throughput by up to at a saturating batch size of 16, whereas the latency-friendly mapping is preferable in lower-batch contexts.
Orhun Görkem, Athanasios Vasilopoulos, Georgios Pagonis, Victoria Clerico, Hadjer Benmeziane, Irem Boybat, Hsinyu Tsai, Abu Sebastian, and William Andrew Simon

Figure 5. Overview of the CAMP mapping algorithm.
Orthogonally, we further vary the inference context by changing the attention granularity. If attention is conducted per token on-chip in a streamed fashion, it does not prevent tokens from executing in parallel across different transformer layers. Then throughput-friendly mapping is preferable with potentially high BP. In contrast, when attention is disaggregated off-chip and operates in a batched fashion such that static MVMs and attention cannot overlap across tokens, the more balanced mapping outperforms the throughput-friendly mapping. Thus, because the optimal layout depends on the inference context, a context-agnostic mapping strategy [3, 5, 18] may not fully realize the computational potential of the system. Our work targets precisely this gap.
4 CAMP Mapping Algorithm
To exploit this mapping flexibility and maximize 3D-IMC throughput, CAMP uses the three-stage flow illustrated in Figure 5. CAMP comprises profiling, initial-placement, and refinement phases, described in the following subsections.
4.1 Profiling phase
The profiling phase quantifies the temporal proximity between MVMs while accounting for the target architecture, model, and runtime context. This information is subsequently used to identify MVMs that are likely to execute concurrently and thus should occupy disjoint sets of LGs, enabling BP.
First, we trace model execution under the expected runtime context and lower the resulting computation to a graph-based Intermediate Representation (IR). The IR is then parsed to identify the dimensions of each MVM mapped to the
3D-IMC macro and the estimated latencies of other operations, including layer normalization, activation functions, and attention. A system-level simulator then schedules the computational graph to extract network runtime metrics. During this profiling phase, we relax the physical resource constraints by providing enough tiles to map every MVM with 4-way TP onto mutually exclusive LGs. This configuration allows all independent MVMs to execute concurrently, exposing their maximum potential temporal overlap, without contention for compute resources.
The simulation provides a schedule of operations consisting of their start and end times. Let denote the set of MVMs in the workload. For each MVM and each token , where is the batch size, the schedule defines start and end times and .
The schedule satisfies two constraints: (i) two tokens cannot execute the same MVM concurrently, since they contend for the same physical array; (ii) data dependencies prevent the MVMs of a single token from executing concurrently, except for the expert layers of MoE-based networks.
Given this schedule, we quantify the temporal overlap between two MVMs and by summing the overlap of all pairs of their token instances:
The temporal proximity of to , , is defined as:
Thus, represents the portion of MVM 's execution that potentially overlaps with MVM . Scheduling constraints (Equation 1) ensure that no overlap is double-counted. The resulting conflict matrix is:
For dense LLMs, diagonal entries are zero because an MVM cannot conflict with itself during placement. For MoE-based LLMs, however, multiple expert instances of the corresponding dense MVM can execute concurrently, requiring the different treatment described below.
4.1.1 Expanding the conflict matrix for MoE LLMs. For dense LLMs, the set of MVMs contains the QKV, output, G+U, and down projections of each transformer layer. In an MoE-based model, each G+U and down projection is instead replicated across expert MVMs, of which are activated per token.

Figure 6. Conflict matrices shown as heatmaps across workload configurations and inference contexts. An entry in row i and column j corresponds to the temporal proximity of MVMs i and j among the set of MVMs to be mapped.
Representing expert-level conflicts introduces two considerations. First, multiple experts in the same FFN block are activated concurrently. Thus, the self-conflicts (diagonal entries in the conflict matrix) corresponding to FFN blocks are non-zero, unlike those of dense FFN blocks. Second, expert activation is not perfectly uniform: some expert subsets are activated more frequently than others. To model expert-level conflicts, we decompose the FFN MVMs into individual expert MVMs. Let denote the expanded set of MVMs. For an expert MVM , contains one entry for each expert , whereas a non-expert MVM remains represented by a single entry . We define a mapping from to :
This mapping associates each expanded MVM with its corresponding MVM in the dense network. for a non-expert MVM. We expand the dense conflict matrix into the more expressive :
The weighting function distributes each dense-MVM conflict among the corresponding expert pairs in proportion to their use. Equation 6 conserves each row: for any and original MVM , the expanded entries sum to the original conflict, . For a perfectly balanced MoE network, is constant and distributes conflicts uniformly across experts. Appendix B defines for non-uniform expert-activation distributions. For simplicity, we write and throughout the remainder of the paper; for MoE models these denote the expanded and .
4.1.2 Inference context encoded by the conflict matrix. The conflict matrix captures all three categories of inference context, as illustrated by the heatmaps in Figure 6. Architectural characteristics: Figure 6(b,c) compares conflict matrices for the settings with on-chip and off-chip attention units, respectively. When the attention unit is integrated on-chip, as in [5, 47], individual batch tokens can be streamed
Algorithm 1 Initial placement phase and placement algorithm
Require: MVMs in computation order; conflict matrix ; leaf groups ; tier budget
Ensure: mapping whether MVM occupies leaf group in tier
1: ;
2: return
3: function
4:
5: for all do
6:
7:
8: for all do
9:
10:
11:
12: end for
13:
14: end for
15: return
16: end function
into the attention unit at fine granularity, enabling continuous inter-layer overlap across tokens in the batch. This fine-grained overlap produces the connected conflict matrix in Figure 6(b). When the attention unit is disaggregated off-chip [46], gathering the accelerator outputs for off-chip communication introduces a barrier between layers, preventing overlap between the preceding QKV projection layer and the subsequent output projection layer. This barrier produces the disconnected conflict matrix in Figure 6(c).
Network characteristics: Figure 6(a-c) represents Llama 70B, whereas Figure 6(d,e) represents Mixtral 8×7B with expert layers decomposed into individual experts. Incorporating the expected expert-activation distribution allows CAMP to account for co-activation likelihood.
Runtime characteristics: Figure 6(a,b) illustrates how batch size affects the conflict matrix. Smaller batch sizes produce
Orhun Görkem, Athanasios Vasilopoulos, Georgios Pagonis, Victoria Clerico, Hadjer Benmeziane, Irem Boybat, Hsinyu Tsai, Abu Sebastian, and William Andrew Simon
Algorithm 2 Refinement phase
Require: initial mapping ; beam width ; action width Ensure: refined mapping 1: 2: ; ; ; 3: while do 4: 5: for all do 6: 7: actions in 8: for all do 9: 10: 11: 12: end for 13: end for 14: 15: states in 16: end while 17: return from
fewer potential conflicts between MVM pairs and therefore sparser conflict matrices.
Note that the conflict matrix is just an intermediate result, guiding the rest of the algorithm when mapping the weights. The next two phases run in a workload-agnostic manner as all the workload-related characteristics are encoded into the conflict matrix.
4.2 Initial placement phase and placement algorithm
The initial placement phase produces the first weight mapping from the profiling results. Algorithm 1 describes the placement process. Because the PLACE function is greedy and order dependent, MVMs are first arranged in computation order, following the heuristic in [5].
Once ordered, MVMs are placed consecutively. For each MVM and its TP option, , we first compute its storage footprint in terms of the number of LGs () and vertical tiers () required. We then enumerate all combinations of at least LGs that can be targeted by a single H-tree broadcast step, together with their first consecutive empty tiers, to form the set of candidate mappings. Each candidate is scored by a scoring function , using the conflict matrix to quantify the weighted conflicts between the MVMs already placed and the candidate mapping. The candidate with the minimum total weighted conflict is picked. This process is repeated until all MVMs are mapped.
During initial placement, we assign a 1-way TP option to every MVM. This minimizes the number of tiles, leaves, and LGs required by each MVM, at the cost of occupying more vertical tiers. This configuration serves as a starting point for the refinement phase.
4.3 Refinement phase
The refinement phase iteratively improves mapping by modifying the TP options of individual MVMs. CAMP explores the search space of TP degree combinations using a beam search with the system-level simulator in the feedback loop. Algorithm 2 presents the refinement pseudocode.
Initially, all MVMs are mapped using 1-way TP, maximizing BP at the cost of TP. The refinement phase determines whether increasing the TP degree of selected MVMs provides a favorable trade-off between lower individual MVM latency and compromised BP. We call such a revision an action: changes MVM from -way to -way TP. Applying an action yields a new mapping, and the pair of a mapping and its latency forms a state . Since evaluating every assignment is intractable, CAMP keeps only the most promising states after each iteration, a beam of width . The search begins from a single state, the initial placement, with candidate actions:
Each iteration proceeds as follows. For every state in the beam, CAMP orders the candidate actions by the compute latency of their corresponding MVMs under that state's TP degrees, prioritizing higher-latency MVMs, and expands the top . Expanding an action updates the TP option of its MVM and remaps the weights of all MVMs using PLACE from Algorithm 1. The system-level simulator then evaluates the resulting mapping and yields its latency , producing a new state . Of the states generated this way, the with the lowest latency form the next beam. When no candidate actions remain, CAMP returns the mapping of the lowest-latency state explored.
As beam width and action width approach infinity, beam search approaches exhaustive exploration of the TP configuration space. In practice, their values balance search quality against simulation cost, thus depending on the number of MVMs and the cost of each simulation. Appendix C.1 analyzes the scale of the weight-mapping problem and shows that exhaustive exploration is infeasible at this scale, while Appendix C.2 provides ablations on and .
5 Experimental setup
5.1 3D-IMC macro configuration
We consider a , 320-tier AIMC tile [7], with 1,024 such tiles required to accommodate the parameter counts of SotA LLMs such as Llama-3.1-70B and Mixtral-87B. The MVM latency of each AIMC tile is 100 ns, consistent with [5]. Leaves are interconnected by an H-tree architecture similar to the designs in [20, 37]. Further, we parameterize the number of H-tree channels available for transmitting data. Each channel has a width matched to the tile dimension, 512, and is deeply pipelined, allowing 64 8-bit inputs to be transmitted each cycle. We use LGs with leaves per group, and four H-tree channels. Appendix A.1 presents the ablation supporting these choices and results for other macro configurations.
5.2 Attention/MVM disaggregation setup
Our speedup evaluation targets the memory-bound decode phase. Within decode, we apply attention/static MVM disaggregation, assigning static MVMs to the 3D-IMC accelerator, while assigning attention to the attention unit(s) under varying configurations, such as 1 or 2 NVIDIA A100 GPUs (80GB), H100 GPUs (80GB), or B200 GPUs (180 GB).
5.3 Target models and mapping configuration
We evaluate CAMP on Llama-3.1-8B/70B [40], Qwen-72B [2], and Mixtral-8×7B [21]. Results are obtained by combining GPU-profiled attention benchmarks with a Torch-integrated 3D-IMC simulator. The details on profiling GPU-related metrics are provided in Appendix D.
Ideally, mapping all layers at once with CAMP would yield the most efficient solution. The runtime of the proposed algorithm, however, scales quadratically with the number of MVMs being mapped. A detailed complexity analysis is provided in Appendix C.3. As a tradeoff between mapping runtime and inter-layer pipelining, we run CAMP on eight layers for the dense networks and replicate the resulting mapping across the remaining layers. For Mixtral, we run CAMP on groups of four layers, solving for each group independently, as expert activation distributions differ across layers unless a uniform distribution is assumed. We allocate the vertical tiers in proportion to the number of layers being mapped, so that the total number of occupied tiers remains feasible. Mixtral results are averaged over 50 trials to mitigate the randomness of expert activation, which corresponds to 1600 × batch size expert-pair samples.
5.4 Comparison baselines
We compare CAMP mapping results against two 3D-IMC weight-mapping algorithms from the literature:
-
Greedy-Util [5]: The Greedy-Util benchmark greedily maps MVMs in execution order, maximizing TP for all MVMs. The algorithm selects the set of accelerator tiles with the lowest tile utilization, computed by counting the number of non-empty tiers on each tile. For expert MVMs, this count is weighted by 1/E. As a result, sibling expert MVMs are stacked onto the same set of tiles. We use Greedy-Util as the primary baseline because of its systematic approach and similarity to our target use case.
-
3D-aCortex [3]: The 3D-aCortex benchmark greedily maps MVMs with maximized TP, repeating the mapping process times (1000 was chosen here) with randomized MVM orderings. The mapping with the fewest vertical tiers is then selected.
-
Full-compute: We propose an idealized performance upper bound that represents the potential throughput if the 3D-IMC macro's compute resources remain fully utilized throughout inference. This is computed by configuring all MVMs with the maximum degree of TP and allowing weight remapping, e.g., allowing any MVM to run on any open set of LGs with no additional cost. While such behavior cannot be expected from any mapping algorithm in reality due to the poor write and endurance characteristics of NVM devices [19], this assumption nevertheless serves as a useful reference, representing the compute roofline of the 3D-IMC accelerator.
6 Experimental Results
In this section, we analyze CAMP's throughput and robustness across various settings, including the target LLM, runtime context, system configuration, additional constraints, and end-to-end performance implications. Supplementary results exploring expanded analyses and ablations are deferred to the Appendix.
6.1 3D-IMC accelerator performance improvement
We first analyze CAMP's throughput benefit within the scope it directly affects: the execution of MVMs on the 3D-IMC accelerator during the decode phase. Figure 7 presents the throughput results normalized to the Greedy-Util baseline.
At smaller batch sizes, BP is limited, with no BP at a batch size of 1. Accordingly, for dense LLMs such as Llama and Qwen, the TP-maximizing baselines are optimal as only TP is available, with CAMP matching their performance. However, for MoE-based LLMs, EP provides an additional source of parallelism even in single-batch workloads. Consequently, the full-compute bound projects a modest 1.15× speedup for Mixtral inference, while CAMP achieves an average throughput speedup of 1.10×, reaching up to 1.14× depending on the experts activated by the batch.
As batch size increases, improving BP becomes favorable. Throughput gains reach 1.95× for Llama 8B, 1.91× for Llama 70B, and 2.0× for Qwen 72B. For Mixtral, CAMP achieves a 1.71× average speedup and up to a 1.84× maximum speedup. We observe that CAMP does not always maximize the TP degree of each MVM, allowing mutually exclusive sets of tiles and LGs to be allocated to different MVMs. Although this increases the compute latency of individual MVMs, the additional latency is offset by an increase in BP.
The gap between CAMP and Full-compute widens as the batch size increases. The underlying assumption that any MVM may occupy any free LG becomes more prominent as more MVMs compete for compute space, resulting in less feasible mappings and loosening the upper bound. Even so, CAMP eliminates a majority of the throughput gap between the baselines and this theoretical upper bound.
Orhun Görkem, Athanasios Vasilopoulos, Georgios Pagonis, Victoria Clerico, Hadjer Benmeziane, Irem Boybat, Hsinyu Tsai, Abu Sebastian, and William Andrew Simon

Figure 7. MVM speedup across mapping algorithms, workloads, and batch sizes. An additional plot for ongoing compute utilization in terms of the number of active LGs is also appended.

Figure 8. Normalized Llama 70B throughput vs. vertical tier count across mapping algorithms.
6.2 Impact of tier count on throughput
Although we adopt a 320-tier design [7], 3D-IMC macros may provide different memory capacities, affecting throughput by limiting mapping flexibility. Figure 8 illustrates this effect. Limiting the design to 280 vertical tiers reduces throughput at batch sizes 4, 8, and 16, where high BP was previously obtained at the cost of some TP. Conversely, relaxing the tier limit to 360 or 380, consistent with ongoing trends in 3D-memory technology, provides additional mapping flexibility and higher throughput.
Greedy-Util and 3D-aCortex, on the other hand, are agnostic to these resource limits. 3D-aCortex always optimizes for the number of occupied tiers and settles on the mapping with the smallest tier occupancy among the sampled candidates, while Greedy-Util simply fills the tiers from bottom to top in MVM computation order. Both therefore reach the same level of throughput regardless of the number of available tiers, with small fluctuations stemming from randomness in the 3D-aCortex algorithm.

Figure 9. Llama 70B speedup with mappings tuned by CAMP for batch sizes 1 and 8, compared with Greedy-Util. The two mappings remain robust across batch sizes, avoiding remapping and weight programming for new batch sizes.
6.3 Robustness across changing runtime context
Due to the adaptivity of CAMP to different inference contexts, a mapping obtained under the expectation of a single-batch inference differs substantially from one obtained for batch size 8. This can raise concerns when the inference context is highly variable, i.e., when the batch size changes during LLM serving. We therefore analyze robustness in Figure 9, which shows that a mapping tuned for batch size 8 outperforms Greedy-Util at all batch sizes 4. Thus, with only two mapping options, one tuned for single-batch and one tuned for large batches, all batch sizes can be served more efficiently than with the Greedy-Util alternative.
6.4 Impact of W and k on CAMP performance
Figure 10 illustrates the impact of parameters W and k on CAMP performance when mapping Llama 70B with a batch size of 8. The first point to note is that maximizing BP as performed in the initial mapping phase already provides superior latency over Greedy-Util. Refinement further improves gains, as the optimal balance between TP and BP lies somewhere between the two extremes. Optimization curves indicate that more exhaustive searches enabled by larger W and k values achieve further improved latencies. We note that these improvements are small at ~5%. We further note that we terminated the beam search after 400 non-improving

Figure 10. Optimization curves illustrating latency improvement during the refinement phase with different beam search parameters W and k. The target workload is Llama 70B with a batch size of 8.
action evaluations in these tests, a limit that was chosen empirically and conservatively. Appendix C.2 provides further analysis of beam parameters.
6.5 Mapping implications on end-to-end latency
While the preceding results demonstrate substantial throughput gains for MVMs, we now examine how these gains propagate to end-to-end decoding performance. In this section, we present system-level simulation results that pair the 3D-IMC accelerator with various GPUs operating as attention units. Due to Amdahl's law, a substantial speedup in the 3D-IMC accelerator has limited impact on end-to-end performance when KV loading and attention computation dominate the inference runtime. Figure 11 presents the end-to-end speedups over 2xA100/H100 GPU baselines across 3D-IMC-enabled systems complemented with different attention units and sequence lengths for Greedy-Util and CAMP. With an A100 attention unit and a sequence length of 4096, weight-mapping optimization provides minimal throughput improvement because attention dominates inference runtime. Reducing sequence length, for example through KV-cache compaction or by targeting shorter-context workloads, increases the benefit: at a sequence length of 128, CAMP raises the 3D-IMC + A100 speedup over baseline to 5.5×, compared to 4.4× with Greedy-Util. More powerful GPUs, reduced-precision KV caching, and sharing the 3D-IMC accelerator across multiple GPUs further balance attention and MVM overheads. When batches from different GPUs are interleaved for execution of their MVMs on the 3D-IMC accelerator, AIMC-side utilization increases, making weight-mapping optimization even more important. Applying these strategies together translates 3D-IMC accelerator throughput gains to a 16.3× end-to-end throughput improvement over the GPU baseline at a sequence length of 4096, up from 12.7× for Greedy-Util.
Because KV loading bottlenecks nearly all inference stacks at long context, many works address it directly through KV compression [38, 45, 48], memory-centric accelerators [12, 15, 29], and architectural alternatives such as SSMs [11]. As
these techniques relieve the KV bottleneck, the share of end-to-end latency governed by weight mapping grows, further reinforcing its importance. Moreover, short-sequence use cases should not be underestimated. Even today, the MVM-bound regimes which benefit from optimized mapping cover important deployments, including edge assistants, short-form Question Answering (QA), and classification, where requests are short (e.g., 99% of Alpaca [39] prompts contain fewer than 114 tokens).
7 Related work
3D-IMC is an emerging computing paradigm whose architectural and system-level design principles are still under active exploration [3, 5, 10, 20, 25, 36, 37]. Despite bringing significant improvements to the 3D-IMC domain from architectural [37], dataflow [20], and application [10] perspectives, a large portion of the prior art does not reveal specific weight mapping details.
Among concrete weight mapping contributions in the literature, 3D-aCortex [3] stands out as one of the pioneering works in this domain, leveraging 3D-NAND flash arrays for Deep Neural Network (DNN) acceleration. In addition, our primary baseline, Greedy-Util, is based on the mapping methodology proposed in [5]. That work pioneers the use of 3D-IMC for MoE workloads by exploiting the alignment between the sparse computational structure of MoEs and the compute-storage capacity imbalance inherent in 3D-IMC.
PackMyWeights [17] is a mapping work in the IMC domain that compares “stacked” and “flattened” mapping layouts to fit as many weights as possible into SRAM IMC and thereby avoid weight-reloading costs. HD-MoE [18] targets 3D-DRAM near-memory processing and optimizes the trade-off between TP and EP using a Mixed-Integer Linear Programming (MILP)-based method. As these works are proposed for different memory technologies, their compute constraints and communication characteristics differ from ours, which limits their applicability to 3D-NVM-based AIMC. In the domain of NVM-based 3D-IMC, CAMP is, to the best of our knowledge, the first work that targets weight mapping optimization at this scale of robustness and efficiency.
8 Conclusion
CAMP adapts to the expected LLM inference context to maximize compute utilization in 3D-IMC-based LLM accelerators by exploiting available tensor-, batch-, and expert-parallels opportunities. After encoding the inference context in a conflict matrix, CAMP uses a profiling-driven feedback process to tune weight placement and improve throughput over context-agnostic mapping baselines. Our experiments show that static MVM throughput increases by up to 2.0× and that much of this improvement propagates to end-to-end performance when the system includes efficient
Orhun Görkem, Athanasios Vasilopoulos, Georgios Pagonis, Victoria Clerico, Hadjer Benmeziane, Irem Boybat, Hsinyu Tsai, Abu Sebastian, and William Andrew Simon

Figure 11. End-to-end decode phase speedup of Llama 70B with a 3D-IMC accelerator paired with various attention units, relative to the 2×A100/H100 GPU baselines. Batch sizes of 16/16/64 are utilized for A100/H100/B200 GPUs, respectively. In the 2-GPU systems, one 3D-IMC accelerator is shared between two GPUs, each serving the above-mentioned batch sizes.
disaggregated attention units. These gains require only an offline software solution and no hardware modifications.
Acknowledgments
Generative AI was utilized to assist in development of code and for grammatical and typographical proofreading, not for writing. The authors performed due diligence in verifying generated output.
References
[1] Kyle Aubrey and Farshad Ghodsian. 2026. Inside NVIDIA Groq 3 LPX: The Low-Latency Inference Accelerator for the NVIDIA Vera Rubin Platform. https://developer.nvidia.com/blog/inside-nvidia-groq-3-lpx-the-low-latency-inference-accelerator-for-the-nvidia-vera-rubin-platform/ NVIDIA Technical Blog.
[2] Jinze Bai, Shuai Bai, Yunfei Chu, Zeyu Cui, Kai Dang, Xiaodong Deng, Yang Fan, Wenbin Ge, Yu Han, Fei Huang, Binyuan Hui, Luo Ji, Mei Li, Junyang Lin, Runji Lin, Dayiheng Liu, Gao Liu, Chengqiang Lu, Keming Lu, Jianxin Ma, Rui Men, Xingzhang Ren, Xuancheng Ren, Chuanqi Tan, Sinan Tan, Jianhong Tu, Peng Wang, Shijie Wang, Wei Wang, Shengguang Wu, Benfeng Xu, Jin Xu, An Yang, Hao Yang, Jian Yang, Shusheng Yang, Yang Yao, Bowen Yu, Hongyi Yuan, Zheng Yuan, Jianwei Zhang, Xingxuan Zhang, Yichang Zhang, Zhenru Zhang, Chang Zhou, Jingren Zhou, Xiaohuan Zhou, and Tianhang Zhu. 2023. Qwen Technical Report. arXiv:2309.16609 [cs.CL] https://arxiv.org/abs/2309.16609
[3] Mohammad Bavandpour, Shubham Sahay, Mohammad Reza Mahmoodi, and Dmitri B. Strukov. 2019. 3D-aCortex: An Ultra-Compact Energy-Efficient Neurocomputing Platform Based on Commercial 3D-NAND Flash Memories. arXiv:1908.02472 [cs.ET] https://arxiv.org/abs/1908.02472
[4] Ashish Reddy Bommana, Farshad Firouzi, and Krishnendu Chakrabarty. 2026. COMET-3D: Compute-in-Memory-Based Transformer Accelerator With Optimized Pipeline and 3D Heterogeneous Integration. IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems 45, 3 (2026), 1418–1431. doi:10.1109/TCAD.2025.3601526
[5] Julian Büchel, Athanasios Vasilopoulos, William Andrew Simon, Irem Boybat, HsinYu Tsai, Geoffrey W. Burr, Hernan Castro, Bill Filipiak, Manuel Le Gallo, Abbas Rahimi, Vijay Narayanan, and Abu Sebastian. 2025. Efficient scaling of large language models with mixture of experts and 3D analog in-memory computing. Nature Computational Science 5, 1 (01 Jan 2025), 13–26. doi:10.1038/s43588-024-00753-x
[6] Zhixiong Chen, Bingjie Zhu, Jiangzhou Wang, Hyundong Shin, Arumugam Nallanathan, and Dusit (Tao) Niyato. 2026. Network Edge Inference for Large Language Models: Principles, Techniques, and Opportunities. ACM Comput. Surv. 58, 12, Article 317 (May 2026), 35 pages. doi:10.1145/3809166
[7] Wanik Cho, Chanhui Jeong, Jongwoo Kim, Jongseok Jung, Keunseon Ahn, Jayoon Goo, Sangkyu Lee, Kayoung Cho, Tei Cho, Dauni Kim, Gwan Park, Yushin Ahn, Sooyeol Chai, Gwihan Ko, Sunyoung Jung, Eunwoo Jo, Taehun Park, Jinhyun Ban, Cheoljoong Park, Jae Hyun Park, Sanghoon Oh, Sojin Jeong, Youngjun Kwak, Kyungsoo Jeong, Jinyeop Kim, Minchol Shin, Eunho Yang, Taisik Shin, Youngil Kim, Jiseong Mun, Changyan Ryu, Huihyeon Park, Changwan Ha, Jong Tai Park, Peng Zhang, Sooyong Park, Rezaul Haque, Hang Tian, Sunghwa Ok, Wonbeom Choi, Junyoun Lim, Dongkyu Yoon, Sechun Park, Wonsun Park, Kichang Gwon, Seungpil Lee, Hwang Huh, Woopyo Jeong, and Jungdal Choi. 2025. A 321-Layer 2Tb 4b/cell 3D-NAND-Flash Memory with a 75MB/s Program Throughput. In 2025 IEEE International Solid-State Circuits Conference (ISSCC), Vol. 68. 512–514. doi:10.1109/ISSCC49661.2025.10904748
[8] Junyong Deng, Lin Jiang, Yun Zhu, Xiaoyan Xie, Xinchuang Liu, Feilong He, Shuang Song, and Lizy Kurian John. 2020. HRM: H-tree based reconfiguration mechanism in reconfigurable homogeneous PE array. Journal of Semiconductors 41, 2 (2020), 022402. doi:10.1088/1674-4926/41/2/022402
[9] Pratyush Dhingra, Janardhan Rao Doppa, and Partha Pratim Pande. 2025. Atlas: Accelerating Transformers on the Edge Enabled by 3D Heterogeneous Manycore Architectures. arXiv:2501.09588 [cs.AR] https://arxiv.org/abs/2501.09588
[10] Pratyush Dhingra, Pramit Kumar Pal, Janardhan Rao Doppa, and Partha Pratim Pande. 2026. ThAME: 3D Memory-Enabled Heterogeneous Accelerator for LLM Mixture of Experts. arXiv:2607.17074 [cs.AR] https://arxiv.org/abs/2607.17074
[11] Albert Gu, Karan Goel, and Christopher Ré. 2022. Efficiently Modeling Long Sequences with Structured State Spaces. arXiv:2111.00396 [cs.LG] https://arxiv.org/abs/2111.00396
[12] Yufeng Gu, Alireza Khadem, Sumanth Umesh, Ning Liang, Xavier Servot, Onur Mutlu, Ravi Iyer, and Reetuparma Das. 2025. PIM Is All You Need: A CXL-Enabled GPU-Free System for Large Language Model Inference. In Proceedings of the 30th ACM International Conference on Architectural Support for Programming Languages and Operating Systems, Volume 2 (Rotterdam, Netherlands) (ASPLOS '25). Association for Computing Machinery, New York, NY, USA, 862–881. doi:10.1145/3676641.3716267
[13] Jinyang Guo, Jianyu Wu, Zining Wang, Jiaheng Liu, Ge Yang, Yifu Ding, Ruihao Gong, Haotong Qin, and Xianglong Liu. 2024. Compressing Large Language Models by Joint Sparsification and Quantization. In Proceedings of the 41st International Conference on Machine Learning (Proceedings of Machine Learning Research, Vol. 235), Ruslan Salakhutdinov, Zico Kolter, Katherine Heller, Adrian Weller, Nuria Oliver, Jonathan Scarlett, and Felix Berkenkamp (Eds.). PMLR, 16945–16957. https://proceedings.mlr.press/v235/guo24g.html
[14] Dan Hendrycks, Collin Burns, Steven Basart, Andy Zou, Mantas Mazeika, Dawn Song, and Jacob Steinhardt. 2021. Measuring Massive Multitask Language Understanding. In International Conference on Learning Representations (ICLR). https://openreview.net/forum?id=d7KBjml3GmQ
[15] Guseul Heo, Sangyeop Lee, Jaehong Cho, Hyunmin Choi, Sanghyeon Lee, Hyungkyu Ham, Gwangsun Kim, Divya Mahajan, and Jongse Park. 2024. NeuPIMs: NPU-PIM Heterogeneous Acceleration for Batched LLM Inferenceing. In Proceedings of the 29th ACM International Conference on Architectural Support for Programming Languages and Operating Systems, Volume 3 (La Jolla, CA, USA) (ASPLOS '24). Association for Computing Machinery, New York, NY, USA, 722–737. doi:10.1145/3620666.3651380
[16] Mert Hidayetoglu, Aurick Qiao, Michael Wyatt, Jeff Rasley, Yuxiong He, and Samyam Rajbhandari. 2026. Shift Parallelism: Low-Latency, High-Throughput LLM Inference for Dynamic Workloads. In Proceedings of the 31st ACM International Conference on Architectural Support for Programming Languages and Operating Systems, Volume 2 (USA) (ASPLOS '26). Association for Computing Machinery, New York, NY, USA, 1749–1763. doi:10.1145/3779212.3790219
[17] Pouya Houshmand and Marian Verhelst. 2024. Pack my weights and run! Minimizing overheads for in-memory computing accelerators. arXiv:2409.11437 [cs.AR] https://arxiv.org/abs/2409.11437
[18] Haochen Huang, Shuzhang Zhong, Zhe Zhang, Shuangchen Li, Dimin Niu, Hongzhong Zheng, Runsheng Wang, and Meng Li. 2025. HD-MoE: Hybrid and Dynamic Parallelism for Mixture-of-Expert LLMs with 3D Near-Memory Processing. arXiv:2509.09420 [cs.PF] https://arxiv.org/abs/2509.09420
[19] Shubham Jain, Hsinyu Tsai, Ching-Tzu Chen, Ramachandran Muralidhar, Irem Boybat, Martin M. Frank, Stanislaw Woźniak, MiLOS Stanisavljevic, Praneet Adusumilli, British Narayanan, Kohji Hosokawa, Masatoshi Ishii, Arvind Kumar, Vijay Narayanan, and Geoffrey W. Burr. 2023. A Heterogeneous and Programmable Compute-In-Memory Accelerator Architecture for Analog-AI Using Dense 2-D Mesh. IEEE Transactions on Very Large Scale Integration (VLSI) Systems 31, 1 (2023), 114–127. doi:10.1109/TVLSI.2022.3221390
[20] Yongjoo Jang, Sangwoo Hwang, Hojin Lee, Sangwoo Jung, Donghun Lee, Wonbo Shim, and Jaeha Kung. 2025. Dissecting and Re-Architecting 3D NAND Flash PIM Arrays for Efficient Single-Batch Token Generation in LLMS. In 2025 IEEE 43rd International Conference on Computer Design (ICCD). 237–244. doi:10.1109/ICCD65941.2025.00040
[21] Albert Q. Jiang, Alexandre Sablayrolles, Antoine Roux, Arthur Mensch, Blanche Savary, Chris Bamford, Devendra Singh Chaplot, Diego de las Casas, Emma Bou Hanna, Florian Bressand, Gianna Lengyel, Guillaume Bour, Guillaume Lample, Lélio Renard Lavaud, Lucile Saulnier, Marie-Anne Lachaux, Pierre Stock, Sandeep Subramanian, Sophia Yang, Szymon Antoniak, Teven Le Scao, Théophile Gervet, Thibaut Lavril, Thomas Wang, Timothée Lacroix, and William El Sayed. 2024. Mixtral of Experts. arXiv:2401.04088 [cs.LG] https://arxiv.org/abs/2401.04088
[22] Dongwook Kim, Dohyun Kim, and Eui-Young Chung. 2025. CPP: Clustered NPU-PIM Heterogeneous Computing Topology for LLM Inference. In 2025 International Technical Conference on Circuits/Systems, Computers, and Communications (ITC-CSCC). 1–6. doi:10.1109/ITC-CSCC66376.2025.11137596
[23] Woosuk Kwon, Zhuohan Li, Siyuan Zhuang, Ying Sheng, Lianmin Zheng, Cody Hao Yu, Joseph Gonzalez, Hao Zhang, and Ion Stoica. 2023. Efficient Memory Management for Large Language Model Serving with PagedAttention. In Proceedings of the 29th Symposium on Operating Systems Principles (Koblenz, Germany) (SOSP '23). Association for Computing Machinery, New York, NY, USA, 611–626. doi:10.1145/3600006.3613165
[24] Haoyang Li, Yiming Li, Anxin Tian, Tianhao Tang, Zhanchao Xu, Xuejia Chen, Nicole HU, Wei Dong, Li Qing, and Lei Chen. 2025. A Survey on Large Language Model Acceleration based on KV Cache Management. Transactions on Machine Learning Research (2025). https://openreview.net/forum?id=z3JZzu9EA3
[25] Fanzi Meng, Xiapeng Xu, Tianze Wu, Xinxin Xu, Xiaojiang Guo, Qiang Tang, and Liang Zhao. 2025. NandPIM: An Optimization Framework for 2D/3D NAND-Based PIM Featuring Genetic Algorithm-based Search of Design Space. In 2025 International Symposium of Electronics Design Automation (ISEDA). 132–137. doi:10.1109/ISEDA65950.2025.11101657
[26] Mohammad Mozaffari, Amir Yazdanbakhsh, and Maryam Mehri Dehnavi. 2025. SLiM: One-shot Quantization and Sparsity with Low-rank Approximation for LLM Weight Compression. In Proceedings of the 42nd International Conference on Machine Learning (Proceedings of Machine Learning Research, Vol. 267), Aarti Singh, Maryam Fazel, Daniel Hsu, Simon Lacoste-Julien, Felix Berkenkamp, Tegan Mahajarj, Kiri Wagstaff, and Jerry Zhu (Eds.). PMLR, 45024–45049. https://proceedings.mlr.press/v267/mozaffari25a.html
[27] Humza Naveed, Asad Ullah Khan, Shi Qiu, Muhammad Saqib, Saeed Anwar, Muhammad Usman, Naveed Akhtar, Nick Barnes, and Ajmal Mian. 2024. A Comprehensive Overview of Large Language Models. arXiv:2307.06435 [cs.CL] https://arxiv.org/abs/2307.06435
[28] Yue Pan, Zihan Xia, Po-Kai Hsu, Lanxiang Hu, Hyungyo Kim, Janak Sharda, Minxuan Zhou, Nam Sung Kim, Shimeng Yu, Tajana Rosing, and Mingu Kang. 2025. Stratum: System-Hardware Co-Design with Tiered Monolithic 3D-Stackable DRAM for Efficient MoE Serving. In Proceedings of the 58th IEEE/ACM International Symposium on Microarchitecture (MICRO '25). Association for Computing Machinery, New York, NY, USA, 1–17. doi:10.1145/3725843.3756043
[29] Jaehyun Park, Jaewan Choi, Kwanhee Kyung, Michael Jaemin Kim, Yongsuk Kwon, Nam Sung Kim, and Jung Ho Ahn. 2024. AttAcc! Unleashing the Power of PIM for Batched Transformer-based Generative Model Inference. In Proceedings of the 29th ACM International Conference on Architectural Support for Programming Languages and Operating Systems, Volume 2 (La Jolla, CA, USA) (ASPLOS '24). Association for Computing Machinery, New York, NY, USA, 103–119. doi:10.1145/3620665.3640422
[30] Xinyu Qu, Zehua Zhang, Runnan Xu, and Yufei Ma. 2025. 3D-MoE: Accelerating Multi-Expert Activated LLMs on 3D In/Near-Memory Computing Architecture via Hybrid Parallelism. In 2025 IEEE/ACM International Conference On Computer Aided Design (ICCAD). 1–9. doi:10.1109/ICCAD66269.2025.11240872
[31] Abu Sebastian, Manuel Le Gallo, Riad Khaddam-Aljameh, and Evangelos Eleftheriou. 2020. Memory devices and applications for in-memory computing. Nature Nanotechnology 15, 7 (2020), 529–544. doi:10.1038/s41565-020-0655-z
[32] Seong Hoon Seo, Junghoon Kim, Donghyun Lee, Seonah Yoo, Seokwon Moon, Yeonhong Park, and Jae W. Lee. 2025. FACIL: Flexible DRAM Address Mapping for SoC-PIM Cooperative On-device LLM Inference. In 2025 IEEE International Symposium on High Performance Computer Architecture (HPCA). 1720–1733. doi:10.1109/HPCA61900.2025.00127
[33] Yakun Sophia Shao, Jason Clemons, Rangharajan Venkatesan, Brian Zimmer, Matthew Fojtik, Nan Jiang, Ben Keller, Alicia Klinefelter, Nathaniel Pinckney, Priyanka Raina, Stephen G. Tell, Yanqing Zhang, William J. Dally, Joel Emer, C. Thomas Gray, Brucek Khailany, and Stephen W. Keckler. 2019. Simba: Scaling Deep-Learning Inference
Orhun Görkem, Athanasios Vasilopoulos, Georgios Pagonis, Victoria Clerico, Hadjer Benmeziane, Irem Boybat, Hsinyu Tsai, Abu Sebastian, and William Andrew Simon
with Multi-Chip-Module-Based Architecture. In Proceedings of the 52nd Annual IEEE/ACM International Symposium on Microarchitecture (Columbus, OH, USA) (MICRO-52). Association for Computing Machinery, New York, NY, USA, 14–27. doi:10.1145/3352460.3358302
[34] Noam Shazeer. 2019. Fast Transformer Decoding: One Write-Head is All You Need. arXiv:1911.02150 [cs.NE] https://arxiv.org/abs/1911.02150
[35] Noam Shazeer, *Azalia Mirhoseini, *Krzysztof Maziarz, Andy Davis, Quoc Le, Geoffrey Hinton, and Jeff Dean. 2017. Outrageously Large Neural Networks: The Sparsely-Gated Mixture-of-Experts Layer. In International Conference on Learning Representations. https://openreview.net/forum?id=B1ckMDqlg
[36] Wonbo Shim, Hongwu Jiang, Xiaochen Peng, and Shimeng Yu. 2021. Architectural Design of 3D NAND Flash based Compute-in-Memory for Inference Engine. In Proceedings of the International Symposium on Memory Systems (Washington, DC, USA) (MEMSYS '20). Association for Computing Machinery, New York, NY, USA, 77–85. doi:10.1145/3422575.3422779
[37] Wonbo Shim and Shimeng Yu. 2021. System-Technology Codesign of 3-D NAND Flash-Based Compute-in-Memory Inference Engine. IEEE Journal on Exploratory Solid-State Computational Devices and Circuits 7, 1 (2021), 61–69. doi:10.1109/JXCDC.2021.3093772
[38] Hanshi Sun, Li-Wen Chang, Wenlei Bao, Size Zheng, Ningxin Zheng, Xin Liu, Harry Dong, Yuejie Chi, and Beidi Chen. 2025. ShadowKV: KV Cache in Shadows for High-Throughput Long-Context LLM Inference. In Proceedings of the 42nd International Conference on Machine Learning (Proceedings of Machine Learning Research, Vol. 267), Aarti Singh, Maryam Fazel, Daniel Hsu, Simon Lacoste-Julien, Felix Berkenkamp, Tegan Maharaj, Kiri Wagstaff, and Jerry Zhu (Eds.). PMLR, 57355–57373. https://proceedings.mlr.press/v267/sun25b.html
[39] Rohan Taori, Ishaan Gulrajani, Tianyi Zhang, Yann Dubois, Xuechen Li, Carlos Guestrin, Percy Liang, and Tatsunori B. Hashimoto. 2023. Stanford Alpaca: An Instruction-following LLaMA model. https://github.com/tatsu-lab/stanford_alpaca.
[40] Hugo Touvron, Thibaut Lavril, Gautier Izacard, Xavier Martinet, Marie-Anne Lachaux, Timothée Lacroix, Baptiste Rozière, Naman Goyal, Eric Hambro, Faisal Azhar, Aurelien Rodriguez, Armand Joulin, Edouard Grave, and Guillaume Lample. 2023. LLaMA: Open and Efficient Foundation Language Models. arXiv:2302.13971 [cs.CL] https://arxiv.org/abs/2302.13971
[41] HsinYu Tsai, Hadjer Benmeziane, Irem Boybat, Julian Büchel, British Narayanan, Manuel Le Gallo, Shubham Jain, Athanasios Vasilopoulos, William Simon, Kohji Hosokawa, Masatoshi Ishii, Yasuteru Kohda, An Chen, Charles Mackin, Kaoutar El Maghraoui, Atsuya Okazaki, Alexander M. Friz, Jose Luquin, Abu Sebastian, Vijay Narayanan, and Geoffrey W. Burr. 2025. Analog AI Accelerators for Transformer-based Language Models: Hardware, Workload, and Power Performance. In 2025 IEEE International Memory Workshop (IMW). 1–4. doi:10.1109/IMW61990.2025.11026974
[42] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Proceedings of the 31st International Conference on Neural Information Processing Systems (Long Beach, California, USA) (NIPS'17). Curran Associates Inc., Red Hook, NY, USA, 6000–6010. https://dl.acm.org/doi/10.5555/3295222.3295349
[43] Naveen Verma, Hongyang Jia, Hossein Valavi, Yinqi Tang, Murat Ozatay, Lung-Yen Chen, Bonan Zhang, and Peter Deaville. 2019. In-Memory Computing: Advances and Prospects. IEEE Solid-State Circuits Magazine 11, 3 (2019), 43–55. doi:10.1109/MSSC.2019.2922889
[44] Jason Wei, Yi Tay, Rishi Bommasani, Colin Raffel, Barret Zoph, Sebastian Borgeaud, Dani Yogatama, Maarten Bosma, Denny Zhou, Donald Metzler, Ed H. Chi, Tatsunori Hashimoto, Oriol Vinyals, Percy Liang, Jeff Dean, and William Fedus. 2022. Emergent Abilities of Large Language Models. Transactions on Machine Learning Research (2022).
https://openreview.net/forum?id=yzkSU5zdwD
[45] Guangxuan Xiao, Yuandong Tian, Beidi Chen, Song Han, and Mike Lewis. 2024. Efficient Streaming Language Models with Attention Sinks. In The Twelfth International Conference on Learning Representations. https://openreview.net/forum?id=NG7sS51zVF
[46] Weihong Xu, Haein Choi, Po-Kai Hsu, Shimeng Yu, and Tajana Simunic. 2026. SLIM: A Heterogeneous Accelerator for Edge Inference of Sparse Large Language Model via Adaptive Thresholding. ACM Trans. Embed. Comput. Syst. 25, 3, Article 46 (May 2026), 28 pages. doi:10.1145/3750727
[47] Zhongkai Yu, Shengwen Liang, Tianyun Ma, Yunke Cai, Ziyuan Nan, Di Huang, Xinkai Song, Yifan Hao, Jie Zhang, Tian Zhi, Yongwei Zhao, Zidong Du, Xing Hu, Qi Guo, and Tianshi Chen. 2024. Cambricon-LLM: A Chiplet-Based Hybrid Architecture for On-Device Inference of 70B LLM. In Proceedings of the 2024 57th IEEE/ACM International Symposium on Microarchitecture (Austin, TX, USA) (MICRO '24). IEEE Press, 1474–1488. doi:10.1109/MICRO61859.2024.00108
[48] Amir Zandieh, Majid Daliri, Majid Hadian, and Vahab Mirrokin. 2026. TurboQuant: Online Vector Quantization with Near-optimal Distortion Rate. In The Fourteenth International Conference on Learning Representations. https://openreview.net/forum?id=tO3ASKZlok
A Architectural characteristics impact analysis
This appendix analyzes CAMP's adaptability to varying architectural design choices and constraints.
A.1 3D-IMC macro topology design space exploration
As indicated in Section 5, the number of tiles in the 3D-IMC macro is fixed at 1,024 due to capacity requirements for serving modern LLM workloads. However, the hierarchical configuration of the 3D-IMC macro, represented as , where , , and denote the number of LGs, the number of leaves per LG, and the number of tiles per leaf, respectively, remains a flexible design parameter that can have significant performance implications.
The first consideration is TP capacity. Structurally, accumulation is performed within LGs, where the accumulation units are located. Increasing the number of tiles within an LG allows more partial sums to be computed concurrently, thereby enabling a higher degree of TP. For example, the configuration has 64 tiles per LG, whereas the configuration has only 8 tiles per LG, resulting in more limited TP.
The second consideration is output granularity. A leaf cannot generate more than one output tensor because the partial sums from the tiles within a leaf are always accumulated. Therefore, at most output tensors can be gathered in a single gather step. Consequently, configurations such as and cannot accommodate models with large MVMs, such as Llama 70B, whose MVMs can generate more than 64 output chunks. Detailed ablation results on these trade-offs are presented in Figure 12.
Based on these considerations, we select the configuration, as it provides competitive performance across a range of workloads while offering a favorable trade-off between TP capacity and output granularity.
A.2 H-tree bandwidth
Even when weight mapping enables high BP and EP, communication bottlenecks in the dataflow can prevent MVMs from executing concurrently. To assess the sensitivity of throughput to the H-tree communication bandwidth, we evaluated the system with a varying number of H-tree input and output channels. The results are shown in Figure 13. When communication is limited to a single input/output channel, the BP enabled by the mapping is masked because inputs cannot be broadcast concurrently. As can be seen, CAMP throughput gains vary between and as the channel count is swept from 1 to 4. This indicates that an optimized mapping must be paired with sufficient H-tree bandwidth to fully utilize compute resources.
A.3 MVM latency on 3D-IMC tiles
MVM latency is the time required to compute a MVM on an active tier of a 3D-IMC tile. Depending on the adopted technology, this latency may vary. CAMP has a greater impact with faster AIMC tiles. Figure 13 shows that peak throughput gains occur at an MVM latency of 100 ns. As MVM latency increases, TP becomes more beneficial. Because Greedy-Util maximizes TP by default and CAMP adapts to prioritize TP, the two algorithms converge toward similar mappings.
B Domain-specific expert parallelism in MoEs
Even though the MoE-based networks are trained for uniform utilization of expert MVMs, it is possible to encounter imbalanced utilization of experts at the layer level when prompts from specific domains are used. Figure 14 illustrates this on two example domains. Domain-specific expert-activation imbalances are represented in the mapping process via the expanded conflict matrix in Equation 6. The weighting function uses the joint distribution of expert-activation combinations, computed by averaging over domain specific prompts from the MMLU dataset [14].
Given the set of experts with , of which the top experts are activated per token per layer, let with denote one of such combinations. We specify as the probability that subset is selected for a token at the undecomposed MVM . This distribution can be estimated empirically from a representative set of input prompts: the model is executed over the dataset, the activated expert subset is recorded for each token, and the resulting frequencies are normalized to obtain . Individual and pairwise expert activation probabilities then follow by marginalization:
The corresponding pairwise probabilities are:
for experts and of MVM . Since the conflict matrix represents pairwise conflicts only, no higher-order marginals are required. Given these probabilities, the weights are:
with the convention when is not an expert MVM. The intuition is to use measured co-activation statistics where they matter most, namely between sibling experts of the same MVM, and to fall back on an independence assumption for inter-MVM conflicts. This process produces the differences between the conflict matrices in Figure 6.
Orhun Görkem, Athanasios Vasilopoulos, Georgios Pagonis, Victoria Clerico, Hadjer Benmeziane, Irem Boybat, Hsinyu Tsai, Abu Sebastian, and William Andrew Simon
| B=1 | B=2 | B=4 | B=8 | B=16 | all B | |||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Topology configuration | not enough output granularity | mean | ||||||||||||||||
| 16x4x16 | 1.31x | 1.31x | 1.31x | 1.38x | 1.34x | 1.45x | 1.47x | 1.27x | 1.78x | 1.44x | 1.38x | 2.02x | 1.39x | 1.39x | 1.99x | 1.48x | ||
| 16x8x8 | 1.28x | 1.28x | 1.28x | 1.34x | 1.31x | 1.47x | 1.41x | 1.26x | 2.22x | 1.37x | 1.37x | 2.75x | 1.35x | 1.30x | 2.82x | 1.59x | ||
| 16x16x4 | not enough output granularity | |||||||||||||||||
| 32x2x16 | 1.30x | 1.30x | 1.30x | 1.36x | 1.31x | 1.44x | 1.37x | 1.35x | 1.72x | 1.40x | 1.42x | 1.99x | 1.34x | 1.31x | 1.95x | 1.46x | ||
| 32x4x8 | 1.27x | 1.27x | 1.27x | 1.33x | 1.29x | 1.45x | 1.31x | 1.28x | 2.15x | 1.35x | 1.33x | 2.62x | 1.31x | 1.24x | 2.79x | 1.55x | ||
| 32x16x2 | 1.24x | 1.24x | 1.24x | 1.30x | 1.26x | 1.42x | 1.22x | 1.19x | 2.13x | 1.27x | 1.37x | 2.62x | 1.25x | 1.23x | 2.47x | 1.50x | ||
| 64x2x8 | 1.29x | 1.29x | 1.29x | 1.36x | 1.35x | 1.43x | 1.40x | 1.26x | 1.73x | 1.40x | 1.44x | 1.97x | 1.43x | 1.40x | 1.82x | 1.46x | ||
| 64x4x4 | 1.26x | 1.26x | 1.26x | 1.40x | 1.32x | 1.47x | 1.36x | 1.26x | 2.16x | 1.38x | 1.43x | 2.64x | 1.37x | 1.29x | 2.60x | 1.56x | ||
| 64x8x2 | 1.25x | 1.23x | 1.23x | 1.36x | 1.26x | 1.42x | 1.31x | 1.32x | 2.10x | 1.32x | 1.27x | 2.53x | 1.26x | 1.38x | 2.40x | 1.51x | ||
| 64x16x1 | 1.21x | 1.21x | 1.21x | 1.32x | 1.26x | 1.40x | 1.14x | 1.20x | 2.07x | 1.31x | 1.27x | 2.47x | 1.27x | 1.22x | 2.38x | 1.46x | ||
| 128x2x4 | 1.04x | 1.04x | 1.04x | 1.19x | 1.14x | 1.25x | 1.00x | 1.09x | 1.80x | 1.05x | 1.08x | 2.63x | 1.04x | 1.15x | 2.69x | 1.35x | ||
| 128x4x2 | 1.02x | 1.02x | 1.02x | 1.16x | 1.11x | 1.24x | 1.02x | 1.05x | 1.77x | 1.12x | 1.00x | 2.55x | 1.06x | 1.00x | 2.63x | 1.32x | ||
| 128x8x1 | 1.00x | 1.00x | 1.00x | 1.13x | 1.00x | 1.22x | 1.13x | 1.09x | 1.78x | 1.14x | 1.21x | 2.50x | 1.09x | 1.04x | 2.25x | 1.30x | ||
Speedup vs. the slowest config in the block
1.00x (slowest)
Figure 12. Throughput comparison for Llama 70B in a grid of 3D-IMC macro topology configurations and mapping algorithms. Topology configurations use the format : number of LGs, leaves per LG, and tiles per leaf.
| MVM = 100 ns | MVM = 200 ns | MVM = 400 ns | Speedup | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| B = 1 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | |
| B = 2 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 |
| B = 4 | 1.08 | 1.06 | 1.05 | 1.04 | 1.02 | 1.02 | 1.07 | 1.06 | 1.04 | 1.04 | 1.04 | 1.04 | 1.04 |
| B = 8 | 1.08 | 1.06 | 1.05 | 1.04 | 1.02 | 1.02 | 1.07 | 1.06 | 1.04 | 1.04 | 1.04 | 1.04 | 1.04 |
| H-tree in channels | 1.06 | 1.00 | 1.00 | 1.04 | 1.01 | 1.01 | 1.02 | 1.01 | 1.01 | 1.01 | 1.01 | 1.01 | 1.01 |
| B = 4 | 1.39 | 1.38 | 1.39 | 1.45 | 1.36 | 1.43 | 1.33 | 1.42 | 1.49 | 1.49 | 1.49 | 1.49 | 1.49 |
| B = 8 | 1.34 | 1.57 | 1.54 | 1.45 | 1.34 | 1.41 | 1.30 | 1.34 | 1.18 | 1.18 | 1.18 | 1.18 | 1.18 |
| H-tree out channels | 1.32 | 1.21 | 1.26 | 1.18 | 1.19 | 1.06 | 1.12 | 1.08 | 1.10 | 1.10 | 1.10 | 1.10 | 1.10 |
| B = 8 | 1.45 | 1.84 | 1.91 | 1.50 | 1.75 | 1.84 | 1.09 | 1.53 | 1.47 | 1.47 | 1.47 | 1.47 | 1.47 |
| H-tree out channels | 1.42 | 1.79 | 1.84 | 1.50 | 1.69 | 1.55 | 1.31 | 1.31 | 1.31 | 1.31 | 1.31 | 1.31 | 1.31 |
| H-tree out channels | 1.40 | 1.33 | 1.24 | 1.18 | 1.25 | 1.15 | 1.12 | 1.13 | 1.12 | 1.12 | 1.12 | 1.12 | 1.12 |
Figure 13. Throughput speedup of CAMP over Greedy-Util [5] as the number of input/output channels and MVM latency vary, profiled on Llama 70B.
We evaluate CAMP's robustness across expert-activation distributions induced by different prompt domains. Figure 15 shows that greater expert-activation imbalance produces larger speedups. The speedup over Greedy-Util rises from to when we switch to an imbalanced distribution. This imbalance indicates which expert MVMs should occupy mutually exclusive resources and which can share resources. On realistic samples from the MMLU dataset [14], speedups range from to , reflecting the limited imbalance present. Greedy-Util performance does not vary across domains because it does not enable EP: when all expert MVMs are serialized, the activated experts do not affect

Figure 14. Expert co-activation frequencies with respect to uniform frequency in Mixtral-8×7B for 50 MMLU prompts [14] from the “global facts” (left, layer 31) and “business ethics” (right, layer 11) domains. Although MoE-based networks are trained to balance expert utilization, co-activation frequencies vary across domains and layers.
performance. 3D-aCortex fluctuates slightly, but the variation is within run-to-run noise because it minimizes tier usage without considering expert activations.
C Mapping search space and runtime complexity analysis
This appendix analyzes the bounds of the search space that contains all mapping possibilities and analyzes the runtime complexity of the CAMP algorithm.
C.1 Bounds of the search space cardinality
The size of the mapping search space motivates a search-space-pruning algorithm such as CAMP. The search space

Figure 15. Speedup across expert-activation distributions derived empirically from input domains in the MMLU dataset [14]. “Uniform” and “imbalanced” are synthetic distributions illustrating the extremes. Uniform is fully uniform on expert-co-activations. And for “imbalanced”, we increased coefficient of variation (CV = std/mean) for co-activation probabilities to 0.8 where the realistic domains from MMLU have it between 0.15 and 0.32. Results are averaged over 50 trials.

Figure 16. Estimated number of options for mapping Llama 70B transformer layers onto the modeled 3D-IMC macro. The red curve shows the Monte Carlo estimate; the other curves show conservative lower and upper bounds.
can be compared to a 3D bin-packing problem, in which MVMs represent reshapable 3D boxes that must be packed into a single bin. While exact enumeration of the mapping space is intractable, we characterize its complexity using conservative lower and upper bounds and an unbiased Monte Carlo estimator. Let denote the mapping-space cardinality.
Lower bound: The lower bound can be intuitively described as selecting any mapping such that all MVMs fit within the
bin, and then permuting the location of all identically sized MVMs. The total number of possible permutations represents the lower bound of the search space.
Consider mapping the weights of the set of MVMs from transformer layers. For a conservative bound, we fix the TP degree of each MVM in and partition the MVMs into equivalence groups by size. Let denote the group of MVMs of size , and let denote the set of all groups. Then:
Given any feasible mapping of all MVMs in , the placements of same-sized MVMs can always be exchanged. This gives permutations for each group . Combining the permutations across groups yields Equation 10.
For Llama 70B, each transformer layer contains four distinct sizes of MVMs. Due to the repetitive structure of transformers, these MVMs repeat for layers. When mapping layers of Llama 70B, there are four equivalence groups with MVMs in each. Equation 10 becomes:
This lower bound only permutes same-sized MVMs among their placements; it excludes alternative TP degrees and placement layouts. Even this loose lower bound shows that mapping eight layers of Llama 70B requires at least evaluations to identify the optimum.
Upper bound: System capacity is the limiting factor on the mapping space. To obtain a conservative upper bound on mapping-space cardinality, we assume that the system has no vertical-tier limit. Intuitively, this removes inter-MVM constraints, allowing every MVM to assume all possible shapes. Thus, the permutation of all possible shapes for all possible MVMs represents the upper bound of the mapping search space.
Each MVM in can be mapped to any subset of LGs on the 3D-IMC macro, constrained only by H-tree broadcasting: at each level, the input may propagate left, right, or both, thereby determining the single-pass reachable LGs for weight mapping [8]. Accordingly, there can be such subsets, where is the depth of the H-tree. Then, if the LGs in a subset are already occupied, the weights are simply mapped to one tier above. In this setting, the mapping search space consists of independent decisions, yielding the upper bound:
For Llama 70B, , and for our architectural setting, .
Monte Carlo estimator: In reality, the size of the search space changes as MVMs are mapped, and future MVMs are constrained. Thus, the true search space falls somewhere between the lower and upper bounds.
Orhun Görkem, Athanasios Vasilopoulos, Georgios Pagonis, Victoria Clerico, Hadjer Benmeziane, Irem Boybat, Hsinyu Tsai, Abu Sebastian, and William Andrew Simon
We quantify this via a Monte Carlo simulation that randomly orders the MVMs in and maps them one by one. The number of mapping options for is denoted by . A mapping is picked uniformly at random and committed. The mapped resources are marked as occupied to obey the occupancy constraints. The number of mapping options for a trial is the product of the option counts at each placement step:
is an unbiased estimator of :
Reaching a specific leaf in the Monte Carlo search tree has probability , and the reached leaf returns mapping options. We report the average across trials as the estimated search-space cardinality.
The red Monte Carlo curve in Figure 16 lies between the lower and upper bounds and confirms that exhaustive search is infeasible. Specifically, identifying the optimal mapping for eight layers of Llama 70B requires approximately simulation evaluations. The search space grows further for the MoE-based Mixtral network because decomposing expert MVMs yields 18 MVMs per transformer layer rather than four.
Although exact optimization methods such as MILP may appear applicable, they require proxy objective functions. Developing proxy objectives that capture batch-level overlap and resource-conflict interactions remains future work.
C.2 Impact of and on throughput and search space coverage
As explained in Section 4.3, we adopt a beam search strategy when selecting a good set of TP degrees for the MVMs, with the beam width and the action width serving as tunable parameters that control the exhaustiveness of the search. In the previous section, we also showed the scale of the search space and the impracticality of a fully exhaustive search.
The question that remains is how exhaustive the beam search must become to close the optimality gap between the baselines and the idealized throughput upper bound for the modeled 3D-IMC-based LLM accelerator. Figure 17 shows the relative throughput obtained and corresponding number of mapping evaluations as the and parameters are ablated. When the batch size is 1, the optimization path is straightforward, because the most performant mapping is to maximize the degree of TP for all mapped MVMs. There is therefore no throughput difference between a fully greedy beam search () and more exhaustive configurations. Batch size 8, on the other hand, requires balancing the degrees of TP and BP, so increasing and generally
improves the throughput reached by the beam search. We report our results with the configuration in the other figures and results; we note, however, that they could be improved by 4% had we chosen the more exhaustive option of . This comes at the cost of roughly more mapping evaluations. Nevertheless, even leads to only 3930 evaluations, a relatively low number with respect to the search-space complexity shown in the previous section.
One exceptional data point is , which results in a decrease in throughput compared to the lower action width configurations at the same beam width. The reason is that increasing the action width at contributes little to the exhaustiveness of the search. The most latency-improving action is selected among 10 candidates instead of 1 or 5, but this only makes the search a steepest descent, which is still a purely greedy approach. Getting stuck in a worse local minimum therefore remains possible unless the beam width is increased.
C.3 Runtime complexity of CAMP
CAMP consists of three phases with different complexities. Let denote the number of MVMs to be mapped. The profiling phase maps the MVMs under the assumption of infinite compute resources, so the mapping is a single greedy pass in which each MVM is placed one by one. The complexity of the profiling phase is therefore . The initial mapping phase assigns 1-way TP to every MVM and places them one by one in the same greedy, in-order fashion. The conflict matrix obtained from the profiling phase is consulted during the placement of each MVM, but this adds little cost because the matrix is sparse row-wise. Denoting the average number of non-zero entries per row as , the complexity of the initial mapping phase is , which reduces to when is independent of . The refinement phase is the most time-consuming part of the algorithm. A placement procedure similar to the one in the initial mapping phase is applied iteratively until no further actions remain. At each refinement step, candidate actions are evaluated, where is the beam width and is the action width, and each candidate requires a placement pass costing ; a single step therefore costs . Each MVM admits at most TP-changing actions, so the number of steps is at most . For instance, with 1-, 2-, and 4-way TP, the possible transitions per MVM are 1-to-2 and 2-to-4, giving . Treating , and as constants, the refinement phase costs . The overall complexity is thus with respect to the number of MVMs being mapped, .
As mentioned in Section 5.3, can be lowered by mapping fewer transformer layers at once and replicating the mapping for the rest of the layers. This is a tradeoff between mapping quality and runtime. Another similar tradeoff is tuning the parameters as shown in Section C.2.

a) Normalized throughput
b) Search evaluations
Figure 17. Ablation on parameters of beam width W and top k actions.

Figure 18. Refinement iterations with beam search.
Technically N is not a large number. For example, for Llama 70B with 80 transformer layers N = 320. For Mixtral, when we decompose expert layers into individual MVMs, N = 576. Quadratic complexity is not an issue at this scale. However, each iteration in the refinement step requires invoking the simulator for profile-guided feedback, and simulators can have various latencies depending on their granularity and software stack efficiency. Therefore, we note that the runtime of the weight mapping algorithm is also determined by the runtime of the simulator.
Finally, we note that weight mapping and remapping on NVM-based 3D-IMC are restricted due to endurance limitations. In practice, the weights are programmed once, offline, and then used repeatedly during inference. Weight mapping therefore does not have to meet strict service-level objectives. With quadratic complexity, CAMP balances mapping quality against runtime, sitting between fully greedy methods and exact optimization methods of exponential complexity.
D GPU Profiling
End-to-end GPU-only latencies are measured with vLLM [23] (version 0.18.0) serving an INT8 weight- and activation-quantized variant of Llama 3.1 70B Instruct¹, at a tensor parallelism degree of two. Chunked prefill is enabled, prefix caching is disabled, and the fraction of device memory reserved for the engine (gpu_memory_utilization) is set to 0.9. Disabling prefix caching ensures that every request performs the full amount of work implied by its input sequence length.
For each combination of input sequence length and batch size, the maximum model length (max_model_len) and the maximum number of batched tokens per scheduler step (max_num_batched_tokens) are computed dynamically so that all prefill requests of the batch are admitted in a single scheduler step. The prefill phase therefore completes before generation begins, and no scheduler step mixes prefill and decode work.
¹https://huggingface.co/neuralmagic/Meta-Llama-3.1-70B-Instruct-quantized.w8a8
Orhun Görkem, Athanasios Vasilopoulos, Georgios Pagonis, Victoria Clerico, Hadjer Benmeziane, Irem Boybat, Hsinyu Tsai, Abu Sebastian, and William Andrew Simon
We enable the torch profiler at engine initialization and parse the resulting traces offline. From each trace we retain only the decode-only scheduler steps which can be identified
by a context length of zero and a number of generation tokens equal to the batch size. The reported latency is the mean over ten such steps.