Documente Academic
Documente Profesional
Documente Cultură
100 16-levels per cell; all other memories are based on single level encod-
ing. The read latency and bandwidth is also provided for all memo-
ries.
50
Cell size Area Latency BW CMOS
[F 2 ] [mm2 ] [ns] [GB/s] compatible
0 SRAM 146 1.30 1.99 15.5 yes
0.2 0.4 0.6 0.8 0.25 eDRAM* 33 1.82 0.39 21.6 no
VDD Level pdf NAND Flash* 4 0.60 89.8 22.9 no
Figure 1: Measurements from a 16nm FinFET test chip we fabricated. ReRAM 4 0.31 0.75 13.7 no
The left plot shows the CTTs mean current and 2σ confidence inter- CTT-SLC 8 0.81 0.86 11.4 yes
vals for different programmed levels as a function of VD D . The right CTT-MLC 8 0.38 0.57 61.0 yes
plot shows the distribution of the cell currents measured at VD D =
0.8 V.
Conditioning Circuit
Iref4 Iref3 Iref0
IDmax Iprog Iinit
ID ( Vth)
IDmin
Row Circuit
WL[n-1]
Addr VDD
WL[n]
PE 4 PE 0
ID
WL[n+1]
Figure 3: Example of the level current distributions showing fault
BL SL
probabilities for the initial level, L 0 , and one programmed level, L 4 .
w= -1.3304 FxP
Q2,8 10.10101011 LeNetFC C
P+C
270K 1.91% 2.6 16
12
F
C
S
Zero
0.008
0.008
FxP - 4488 S 0.076
LeNetCNN C 600K 0.85% 2.8 8 8 S 0.021
P+C 11 B MDI 0.021
FxP - 4444FF S 40.53
VGG16 C 135M 37.8% 2.10 64/8 2244/8 S/MDI 5.7
P+C 64/9 444/9 S/MDI 4.9
8-level cell 16-level cell the magnitude and fault rates, see Table 3. The second technique
c3 is an inter-cell, multi-cell per weight optimization. If more than
Clustering one cell is required to store the cluster index, then some clusters
can be more protected via the asymmetrical fault rates of MLC
w = -1.3304 k
means
c3 and non-uniform encoding, i.e., a non-uniform allocation of cluster
index bits across cells.
9-level cell
4 RESULTS
Figure 4: Example of fixed-point non-uniform encoding (top) and To quantify the benefits of using CTT-MLC eNVMs, we use two
cluster-based encoding (bottom) using MLCs. zero added cost baselines: SRAM and CTT-SLC. We evaluate the
effectiveness of CTT devices to store the weights of three prototyp-
As a example, consider the conversion of the value (−1.3304)10 ical NNs listed in Table 2: LeNetFC is a three-layer fully-connected
and its fixed-point representation (10.10101011)2 using two integer (FC) network, LeNetCNN is a five-layer convolutional neural net-
bits and eight fractional bits (see Figure 4). If this value is stored work (CNN), and VGG16 is a much larger CNN [18]. LeNetFC and
using binary encoding with CTT-SLC, then 10 cells are needed (one LeNetCNN use the well-known MNIST dataset for handwritten
per bit). The same value can be stored using only 3 CTT-MLCs if the digit classification, and VGG16 uses the popular ImageNet dataset
most dense, 16 level (4 bits), cell configuration is used. This uniform of colored images to be classified into 1000 possible classes [14, 17].
configuration reduces the area cost per bit at the expense of a higher The fault injection simulations are implemented using the Keras
fault rate. Since faults on higher order bits have a disproportionate framework [5]. For both fixed-point and cluster representations,
impact on the stored value, we anticipate that it is advantageous to a corresponding encoding transform function is defined. Starting
selectively mitigate these faults. from a trained model, the encoding transform is applied to the
Figure 4 shows our proposed alternative: a non-uniform encod- original parameters on a per-layer basis. Next, the faulty cells are
ing where 4 cells are used with 2, 4, 8, and 16 levels per cell, from randomly chosen using the error probability based on the number
MSB to LSB (labeled as 248F using hexadecimal notation). The ex- of levels per cell and the specific level value. The transformed
ample shows that the sign and integer portion of the weight can parameters are used to evaluate the accuracy of the model for a
be protected by using a CTT-MLC with fewer levels. Compared to specific encoding configuration.
uniform encoding, this non-uniform encoding requires only one Section 4.1 presents the benefits of using CTT-MLC memories
additional cell and substantially reduces the fault rates in weight when storing NN parameters that are quantized with fixed-point
MSBs. representation. Section 4.2 explores k-means clustering to reduce
3.2.2 Clustering. The second weight quantization approach we the area footprint of storing NNs. Finally, Section 4.3 improves on
consider is k-means clustering [9], in which NN weights are mapped the preliminary MLC approach by co-designing the NN storage
onto a set of k values on a per-layer basis. Clustering is advanta- scheme with characteristics of faults in CTT-MLC memories.
geous as only the indexes need to be stored per weight and ⌈log k⌉
is typically significantly less than the number of bits required with 4.1 Storing fixed-point values in CTTs
fixed-point quantization. The overhead for storing the look-up table As discussed in Section 3.2.1, non-uniform MLC encoding is used
of the actual k weight values is negligible. to shift the fault rate from the MSBs to the LSBs while reducing the
Storing cluster indexes enables two optimization opportunities. total number of cells compared to binary representation. To find the
The first technique is an intra-cell optimization to protect the initial configuration that minimizes the area footprint while maintaining
state from faults by increasing ∆I init . This technique is particularly model accuracy, all possible configurations of levels per cell and
effective when the majority of the parameters are assigned to a number of cells are tested for each NN. The results of this explo-
single cluster, a property we actively enforce with weight pruning. ration for LeNetCNN are shown in Figure 5. The discrete steps in
We further consider three ways to map clusters to levels to mitigate area correspond to sweeping the number of cells to encode each
On-Chip Deep Neural Network Storage with Multi-Level eNVM DAC ’18, June 24–29, 2018, San Francisco, CA, USA
8-level MSB
Classification error [%]
7.6x
0.88 6.5x
0.86
4488
44444, 24448 Figure 6: Area comparison for SRAM, CTT-SLC, CTT-MLC for
0.059 0.076 0.095 0.112 0.205 0.228 fixed-point encodings.
Area [mm2]
4.2 Reducing area with parameter clustering 4.3.1 Skewing weights to leverage CTT initial state. In CTT-MLC
devices, the initial state (see Figure 3) provides a unique opportunity
As discussed in Section 3.2.2, another way to quantize NNs is with for optimization: because it can be deliberately separated from the
k-means clustering. Clustering is often preferable to fixed-point programmed states, the fault probability can be skewed to protect
quantization because only cluster index pointers are stored. All the most frequent cluster. To further leverage this protected state,
three NN models require between 8 and 64 clusters to preserve we propose pruning small parameter values by setting them to zero.
model accuracy, which requires just 3 to 6 bits to represent each Previous work demonstrated that pruning is a highly effective opti-
parameter. When encoding clustered parameters in CTT-MLC, the mization that can set upwards of 90% of weight values to zero [10].
benefits are immediate. For LeNetFC and LeNetCNN, each parame- Therefore, mapping the zero-valued cluster of the pruned networks
ter can be stored in a single transistor because only 16 and 8 clusters to the initial state has the overall effect of reducing the number of
are needed to preserve accuracy for each model. Compared to fixed- faults. As an example, pruning LeNetFC reduces the raw number
point quantization, k-means clustering saves 3.8× and 3.6× area of faults across all layers by 89%.
when storing LeNetFC and LeNetCNN in CTT-MLCs. Compared to In VGG16, we prune 97% of all parameters in the first FC layer,
SRAM, storing the clusters in CTT-MLCs saves 14.4× and 13.2× for which has over 100M parameters. This effectively protects a much
LeNetFC and LeNetCNN, respectively. larger proportion of the parameters compared to the unpruned
Up to this point, we assumed that all layers in a network use network. In the CNN layers, pruning reduces the number of cells
the same MLC configuration to store NN parameters. This assump- needed to store parameters from 4 to 3, leading to a further area
tion results in pessimistic storage estimates for larger models. For reduction of 1.17× over CTT-MLC with clustering.
DAC ’18, June 24–29, 2018, San Francisco, CA, USA M. Donato et al.
enumerated in Table 3. The most trivial is sequential (S), where On-chip SRAM
the level mapping follows the order of the clusters. The rest of the
mappings assign the most frequent cluster to the initial state. The
zero mapping assigns the remaining clusters sequentially, while
the minimum distance (MD) mappings minimize the fault mag-
13.2x
nitude between adjacent levels. For LeNetFC and LeNetCNN, the
14.4x
level mapping corresponding to negligible accuracy loss changed
after pruning and differed between the two models, as indicated in
Table 2. For VGG16, the level mapping did not significantly affect
CNN results, and the MD-I scheme was preferable for the FC layers.
Figure 7 summarizes results for storing NNs using the optimized
Figure 7: Area comparison for SRAM, CTT-SLC, and CTT-MLC for
encoding scheme including clustering, pruning, and level mapping. clustered encodings. Area for CTT-MLC with clustered and pruned
Using CTT-MLCs allows us to store LeNetFC and LeNetCNN in encodings is also given (orange). The horizontal gray line indicates
0.009 mm2 and 0.021 mm 2 , which corresponds to a 14.4× and 13.2× the memory area footprint from a recently published NN SoC [6],
savings in area compared to SRAM. VGG16 can be stored in 4.9 showing that our most optimized encoding enables VGG16 to fit on
mm 2 , which is a 10.6× reduction over SRAM. chip.
Based on the memory footprint of a recently published NN SoC
policies, either expressed or implied, of the U.S. Government.
fabricated using a 28 nm process, our proposed techniques for co-
Reagen was supported by a Siebel Scholarship.
designing NNs with CTT-MLCs allow us to store a large model like
VGG16 entirely on chip [6]. REFERENCES
[1] I. Bayram, E. Eken, D. Kline, N. Parshook, Y. Chen, and A. K. Jones. Modeling
5 CONCLUSION STT-RAM fabrication cost and impacts in NVSim. In IGSC, 2016.
[2] X. Bi, M. Mao, D. Wang, and H. Li. Unleashing the potential of MLC STT-RAM
We present a co-design methodology based on the concurrent opti- caches. In ICCAD, 2013.
mization of CTT-MLC eNVM and NNs. The storage of fixed-point [3] Y. Cai et al. Threshold Voltage Distribution in MLC NAND Flash Memory:
Characterization, Analysis and Modeling. DATE, 2013.
parameters can be optimized using a non-uniform encoding that [4] A. Chen. A review of emerging non-volatile memory (NVM) technologies and
protects the sign and integer bits using fewer levels per cell, and applications. Solid. State. Electron., 2016.
this solution gives up to 7.6× area savings. As a further optimiza- [5] F. Chollet et al. Keras, 2015.
[6] G. Desoli et al. A 2.9TOPS/W deep convolutional neural network SoC in FD-SOI
tion, using k-means clustering together with MLC storage requires 28nm for intelligent embedded systems. ISSCC, 2017.
just a single transistor for each parameter in FC layers. Additionally, [7] X. Dong et al. NVSim: A Circuit-Level Performance, Energy, and Area Model for
Emerging Nonvolatile Memory. IEEE Trans. Comput. Des. Integr. Circuits Syst.,
pruning NN parameters and fine-tuning the cell level distributions 2012.
protects the most populous cluster and allows for more aggressive [8] Y. Du et al. A Memristive Neural Network Computing Engine using CMOS-
encoding configurations for CNN layers as well. The concurrent Compatible Charge-Trap-Transistor (CTT). CoRR, 2017.
[9] Y. Gong et al. Compressing Deep Convolutional Networks using Vector Quanti-
adoption of these optimizations reduces the memory footprint of zation. CoRR, 2014.
VGG16 to a total area 4.9 mm2 , which can be reasonably integrated [10] S. Han et al. Deep Compression: Compressing Deep Neural Networks with
in a modern SoC. While this work focused on a specific eNVM im- Pruning, Trained Quantization and Huffman Coding. ICLR, 2016.
[11] N. P. Jouppi et al. In-Datacenter Performance Analysis of a Tensor Processing
plementation, our co-design methodology can be extended to any Unit. ISCA, 2017.
eNVM technology capable of MLC storage. This aspect makes our [12] F. Khan et al. The Impact of Self-Heating on Charge Trapping in High-k -Metal-
Gate nFETs. IEEE Electron Device Lett., 2016.
approach generalizable to other popular eNVM implementations [13] F. Khan et al. Charge Trap Transistor (CTT): An Embedded Fully Logic-
such as ReRAM and PCM. Compatible Multiple-Time Programmable Non-Volatile Memory Element for
high-k -metal-gate CMOS technologies. IEEE Electron Device Letters, 2017.
[14] Y. LeCun and C. Cortes. The MNIST database of handwritten digits.
6 ACKNOWLEDGEMENTS [15] K. Miyaji et al. Zero Additional Process, Local Charge Trap, Embedded Flash
This work was supported in part by the Center for Applications Memory with Drain-Side Assisted Erase Scheme Using Minimum Channel
LengthWidth Standard Complemental Metal-Oxide-Semiconductor Single Tran-
Driving Architectures (ADA), one of six centers of JUMP, a Semi- sistor Cell. Jpn. J. Appl. Phys., 2012.
conductor Research Corporation program co-sponsored by DARPA. [16] B. Reagen et al. Minerva: Enabling Low-Power, Highly-Accurate Deep Neural
The work was also partially supported by the U.S. Government, Network Accelerators. ISCA, 2016.
[17] O. Russakovsky et al. ImageNet Large Scale Visual Recognition Challenge. IJCV,
under the DARPA CRAFT and DARPA PERFECT programs. The 2015.
views and conclusions contained in this document are those of the [18] K. Simonyan and A. Zisserman. Very Deep Convolutional Networks for Large-
Scale Image Recognition. CoRR, 2014.
authors and should not be interpreted as representing the official