OurModel.tex 9.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170
  1. \section{Detailed Intermittent Execution Model}
  2. In this section, we describe a detailed execution model of intermittent systems based on our observations from the measurement.
  3. In Sec.~\ref{sec:system_description}, we introduce the typical hardware setup of intermittent systems and the system we collected the data from.
  4. Sec.~\ref{sec:execution_model} presents the key observations from our measurements and proposes our detailed execution model.
  5. \subsection{System Description}
  6. \label{sec:system_description}
  7. \begin{figure}
  8. \centering
  9. \includegraphics[width=\linewidth]{figs/cropped/system.pdf}
  10. \caption{A typical hardware setup of intermittent systems.}
  11. \label{fig:hardware_setup}
  12. \end{figure}
  13. A typical intermittent system consists of two components: a power management system and a computing system.
  14. Fig.~\ref{fig:hardware_setup} illustrates this setup.
  15. The power management system is responsible for collecting the incoming power into energy storage and providing a stable-voltage current to the computing system.
  16. The computing system equips NVMs along with the MCU and peripherals, and utilize the NVMs for state retention between power failures.
  17. This setup has two notable decoupling capacitors that affect the execution model of intermittent systems.
  18. The first one is attached to the power management system, as voltage regulators need a capacitor larger than the required capacitance for correct execution.
  19. Also, the computing system also has a decoupling capacitor.
  20. In this work, our goal is to model the buffering effects of these capacitors and evaluate their implications on software designs.
  21. (Recent studies present the need for better computing capability~\cite{bakarProtean2023a})
  22. For model validation and evaluation, we use a custom-built board equipped with an ARM Cortex-M33 core and XXMB of FRAM.
  23. Our setup requires XXuF and 220uF capacitors for C1 and C2, respectively, for stable execution of checkpoint and recovery.
  24. Sec.~\ref{sec:other_architectures} evaluates our model in different architectures.
  25. \subsection{Execution Model}
  26. \label{sec:execution_model}
  27. \begin{figure}
  28. \centering
  29. \begin{subfigure}{\linewidth}
  30. \includegraphics[width=\textwidth]{figs/plot_expr_8a_cropped.pdf}
  31. \caption{Trace of one power cycle.}
  32. \label{fig:execution_trace_one_cycle}
  33. \vspace{5pt}
  34. \end{subfigure}
  35. \begin{subfigure}{\linewidth}
  36. \includegraphics[width=\textwidth]{figs/plot_expr_8b_cropped.pdf}
  37. \caption{Detailed trace.}
  38. \label{fig:execution_trace_detailed}
  39. \end{subfigure}
  40. \caption{Voltage measurement of capacitor and Vdd (470uF, 1.5mA current supply).}
  41. \label{fig:execution_trace}
  42. \end{figure}
  43. Fig.~\ref{fig:execution_trace} shows the voltage trace of the energy storage and the Vdd of the computing system.
  44. A 470uF capacitor is used for the energy storage to generate execution of xx ms under 1.5mA current supply.
  45. Fig.~\ref{fig:execution_trace_one_cycle} shows the trace during one power cycle, and Fig.~\ref{fig:execution_trace_detailed} presents the first execution cycle in more detail.
  46. Three key observations that affect software designer's decision.
  47. \begin{itemize}
  48. \item \textbf{O1}: The capacitor voltage drops quickly to charge decoupling capacitor when system wakes-up ($t1$--$t2$).
  49. \item \textbf{O2}: The system executes at sub-voltage using the decoupling capacitor, even after power supply stops ($t4$--$t5$).
  50. \item \textbf{O3}: The decoupling capacitor discharges while the system is powered-off (after $t5$).
  51. \end{itemize}
  52. \begin{figure}
  53. \centering
  54. \includegraphics[width=\linewidth]{figs/cropped/detailed_execution_model.pdf}
  55. \caption{Detailed execution model of intermittent systems.}
  56. \label{fig:detailed_execution_model}
  57. \end{figure}
  58. Fig.~\ref{fig:detailed_execution_model} shows our detailed execution model, which reflects all the key observations.
  59. In the following sections, we discuss how this model benefits the software design.
  60. \subsection{Impact on Power Efficiency}
  61. The traditional model implies that power consumed between power-on and power-off thresholds are entirely used for the computing system (including hardware initialization and recovery).
  62. However, our model reveals that huge energy is used for charging the decaps (\textbf{O1}) and discharged during power-off durations (\textbf{O3}).
  63. This implies that much smaller energy is used for the useful computation compared to the designer's expectation.
  64. \begin{figure}
  65. \centering
  66. \includegraphics[width=\linewidth]{figs/plot_expr_5_cropped.pdf}
  67. \caption{Distribution of energy consumed in a power cycle in different capacitor sizes (1mA current supply).}
  68. \label{fig:power_distribution}
  69. \end{figure}
  70. Fig.~\ref{fig:power_distribution} shows the distribution of the energy consumed for each stage of intermittent execution within one power cycle, averaged over XX executions, in various capacitor sizes.
  71. The line represents the average time of useful computation.
  72. The checkpoint is executed by the interrupt from the power management system, which is generated when the capacitor voltage reaches the power-off threshold (3.4V).
  73. Note that this is the last point for checkpoint execution according to the traditional model.
  74. The results shows that significant energy is wasted in decoupling capacitor.
  75. The cost is more expensive when the capacitor size is small since the decaps discharge rate follows the RC-discharging circuits.
  76. While using smaller capacitors shortens the power-off durations, the discharging behavior penalizes them most since XX\% of energy is discharged at the first XX ms.
  77. More importantly, this wasted energy is expected to be used for the computation in traditional execution model, as all the energy except for the initialization and checkpoint/recovery is expected to be used in computations.
  78. It brings significant errors between the two models in available energy for the execution.
  79. In 470uF case, the actual energy efficiency (Execution) and the expectation from the traditional model (Execution and Discharged) differs by XX times.
  80. (Limitations of power failure injection and simulation based evaluations).
  81. \subsection{Impact on Predicting Power Failures}
  82. \begin{figure}
  83. \centering
  84. \begin{subfigure}{\linewidth}
  85. \includegraphics[width=\textwidth]{figs/plot_expr_6a_cropped.pdf}
  86. \caption{Input current is 1mA.}
  87. % \label{fig:eval_voltage_trace}
  88. \vspace{5pt}
  89. \end{subfigure}
  90. \begin{subfigure}{\linewidth}
  91. \includegraphics[width=\textwidth]{figs/plot_expr_6b_cropped.pdf}
  92. \caption{Input current is 3mA.}
  93. % \label{fig:eval_adaptivenss_finished_tasks}
  94. \end{subfigure}
  95. \caption{Ratio of sub-voltage operations in total execution time.}
  96. % \label{fig:}
  97. \end{figure}
  98. According to the traditional model, the system states should be saved to NVM before power-off threshold.
  99. Our model shows that the system may operate after this point using the energy stored in the decaps (\textbf{O2}).
  100. As a result, the energy storage voltage is not a good approximate of the remaining time that system can execute.
  101. \subsection{Impact of Sub-normal Voltage Execution}
  102. The traditional model makes the software designers assume the system is executed under stable voltage.
  103. However, the execution after the power-off threshold (\textbf{O3}) happens in sub-normal voltage.
  104. Being aware of this is important to the software designers since the peripherals and analog components may function differently.
  105. The two most critical examples are Analog-Digital Converter (ADC) and external memory.
  106. \begin{figure}
  107. \centering
  108. \begin{subfigure}{0.45\linewidth}
  109. \includegraphics[width=\textwidth]{figs/plot_expr_2_cropped.pdf}
  110. \caption{Trace of one power cycle.}
  111. % \label{fig:eval_voltage_trace}
  112. \end{subfigure}
  113. \hfill
  114. \begin{subfigure}{0.52\linewidth}
  115. \includegraphics[width=\textwidth]{figs/plot_expr_3_cropped.pdf}
  116. \caption{Detailed trace.}
  117. % \label{fig:eval_adaptivenss_finished_tasks}
  118. \end{subfigure}
  119. \caption{Voltage of the capacitor and Vdd, sampled 470uF and 1.5mA.}
  120. % \label{fig:}
  121. \end{figure}
  122. \subsection{Sensitivity to Architectural Designs}
  123. \label{sec:other_architectures}
  124. Finally, we evaluate our model against two different architectural setups: MSP430 and Cortex-M33 with MRAM.
  125. MSP430 has less computational capability than Cortex-M33 cores.
  126. But it is a most popular platform for intermittent system researches, since it is a low-power system having on-chip FRAM.
  127. We used MSP430FR5994 evaluation board, having 10uF of onboard decap.
  128. For the second setup, we put MRAM to our evaluation platform instead of FRAM.
  129. Core frequencies, capacitance of power management system, input power targeting xx ms execution.
  130. \begin{figure}
  131. \centering
  132. \includegraphics[width=\linewidth]{figs/plot_expr_9_cropped.pdf}
  133. \caption{Energy breakdown and the ratio of sub-voltage operations in different architectures.}
  134. \label{fig:other_architectures}
  135. \end{figure}
  136. Fig.~\ref{fig:other_architectures} shows the results in different power-off voltage.
  137. The bar in the left shows the energy breakdown in one power cycle, and the one in the right represents the ratio of the execution time operated in sub-voltage.