|
|
@@ -1,31 +1,43 @@
|
|
|
close all
|
|
|
+%set(0,'defaulttextinterpreter','latex')
|
|
|
+%set(0,'DefaultTextFontname', 'CMU Serif')
|
|
|
+%set(0,'DefaultAxesFontName', 'CMU Serif')
|
|
|
+%text(0.5, 0.8, '\textsf{sans serif}','interpreter','latex')
|
|
|
data = [
|
|
|
- 0 963;
|
|
|
- 0 663;
|
|
|
- 0 598;
|
|
|
- 0 1076;
|
|
|
- 0 99;
|
|
|
- 0 49;
|
|
|
- 0 55];
|
|
|
+ NaN 963;
|
|
|
+ NaN 663;
|
|
|
+ NaN 598;
|
|
|
+ 618 1076;
|
|
|
+ 59 99;
|
|
|
+ 27 49;
|
|
|
+ 52 55];
|
|
|
grid on
|
|
|
legend
|
|
|
B = bar(1:7,data);
|
|
|
-x_labels = [
|
|
|
- {'\begin{tabular}{r}\texttt{Divide}\\\texttt{FFFFh/0001h}\end{tabular}'}
|
|
|
- {'\begin{tabular}{r}\texttt{Divide}\\\texttt{FFFFh/FFFFh}\end{tabular}'}
|
|
|
- {'\begin{tabular}{r}\texttt{Divide}\\\texttt{0001h/FFFFh}\end{tabular}'}
|
|
|
- {'\begin{tabular}{r}\texttt{Modulus}\\\texttt{FFFFh\%0001h}\end{tabular}'}
|
|
|
- {'\begin{tabular}{r}\texttt{Modulus}\\\texttt{FFFFh\%FFFFh}\end{tabular}'}
|
|
|
- {'\begin{tabular}{r}\texttt{Modulus}\\\texttt{0001h\%FFFFh}\end{tabular}'}
|
|
|
- {'\begin{tabular}{r}\texttt{Multiply 16bit}\end{tabular}'}
|
|
|
-];
|
|
|
-set(gca,'XTickLabel', x_labels, 'TickLabelInterpreter', 'latex')
|
|
|
+x_labels{1} = sprintf('Divide FFFFh/0001h');
|
|
|
+x_labels{2} = sprintf('Divide FFFFh/FFFFh');
|
|
|
+x_labels{3} = sprintf('Divide 0001h/FFFFh');
|
|
|
+x_labels{4} = sprintf('Module FFFFh/0001h');
|
|
|
+x_labels{5} = sprintf('Module FFFFh/FFFFh');
|
|
|
+x_labels{6} = sprintf('Module 0001h/FFFFh');
|
|
|
+x_labels{7} = sprintf('Multiply 16bit');
|
|
|
+set(gca,'XTickLabel', x_labels);
|
|
|
+%x_labels = [
|
|
|
+ %{'\begin{tabular}{r}Divide\\FFFFh/0001h\end{tabular}'}
|
|
|
+ %{'\begin{tabular}{r}Divide\\FFFFh/FFFFh\end{tabular}'}
|
|
|
+ %{'\begin{tabular}{r}Divide\\0001h/FFFFh\end{tabular}'}
|
|
|
+ %{'\begin{tabular}{r}Modulus\\FFFFh\%0001h\end{tabular}'}
|
|
|
+ %{'\begin{tabular}{r}Modulus\\FFFFh\%FFFFh\end{tabular}'}
|
|
|
+ %{'\begin{tabular}{r}Modulus\\0001h\%FFFFh\end{tabular}'}
|
|
|
+ %{'\begin{tabular}{r}Multiply 16bit\end{tabular}'}
|
|
|
+%];
|
|
|
+%set(gca,'XTickLabel', x_labels, 'TickLabelInterpreter', 'latex')
|
|
|
title("Processor cycles per function")
|
|
|
ylabel("Numer of cycles")
|
|
|
-xtickangle(40);
|
|
|
+xtickangle(30);
|
|
|
xtips1 = [1:7] - 0.21;
|
|
|
ytips1 = B(1).YData;
|
|
|
-labels1 = ['N/A'];
|
|
|
+labels1 = string(B(1).YData);
|
|
|
text(xtips1,ytips1,labels1,'HorizontalAlignment','center','VerticalAlignment','bottom');
|
|
|
xtips2 = [1:7] + 0.21;
|
|
|
ytips2 = B(2).YData;
|
|
|
@@ -34,6 +46,7 @@ text(xtips2,ytips2,labels2,'HorizontalAlignment','center','VerticalAlignment','b
|
|
|
|
|
|
legend("RISC", "OISC");
|
|
|
grid on
|
|
|
+%set(gcf, 'Color', 'None')
|
|
|
|
|
|
|
|
|
%%
|