OLD | NEW |
1 import os, re | 1 import os, re |
2 from autotest_lib.client.bin import test, utils | 2 from autotest_lib.client.bin import test, utils |
3 import postprocessing | 3 import postprocessing |
4 | 4 |
5 | 5 |
6 class iozone(test.test): | 6 class iozone(test.test): |
7 """ | 7 """ |
8 This autotest module runs the IOzone filesystem benchmark. The benchmark | 8 This autotest module runs the IOzone filesystem benchmark. The benchmark |
9 generates and measures a variety of file operations. Iozone has been ported | 9 generates and measures a variety of file operations. Iozone has been ported |
10 to many machines and runs under many operating systems. | 10 to many machines and runs under many operating systems. |
(...skipping 16 matching lines...) Expand all Loading... |
27 | 27 |
28 def setup(self, tarball='iozone3_347.tar'): | 28 def setup(self, tarball='iozone3_347.tar'): |
29 """ | 29 """ |
30 Builds the given version of IOzone from a tarball. | 30 Builds the given version of IOzone from a tarball. |
31 @param tarball: Tarball with IOzone | 31 @param tarball: Tarball with IOzone |
32 @see: http://www.iozone.org/src/current/iozone3_347.tar | 32 @see: http://www.iozone.org/src/current/iozone3_347.tar |
33 """ | 33 """ |
34 tarball = utils.unmap_url(self.bindir, tarball, self.tmpdir) | 34 tarball = utils.unmap_url(self.bindir, tarball, self.tmpdir) |
35 utils.extract_tarball_to_dir(tarball, self.srcdir) | 35 utils.extract_tarball_to_dir(tarball, self.srcdir) |
36 os.chdir(os.path.join(self.srcdir, 'src/current')) | 36 os.chdir(os.path.join(self.srcdir, 'src/current')) |
| 37 utils.system('patch -p3 < ../../../makefile.patch') |
37 | 38 |
38 arch = utils.get_current_kernel_arch() | 39 arch = utils.get_current_kernel_arch() |
39 if (arch == 'ppc'): | 40 if (arch == 'ppc'): |
40 utils.make('linux-powerpc') | 41 utils.make('linux-powerpc') |
41 elif (arch == 'ppc64'): | 42 elif (arch == 'ppc64'): |
42 utils.make('linux-powerpc64') | 43 utils.make('linux-powerpc64') |
43 elif (arch == 'x86_64'): | 44 elif (arch == 'x86_64'): |
44 utils.make('linux-AMD64') | 45 utils.make('linux-AMD64') |
45 else: | 46 else: |
46 utils.make('linux') | 47 utils.make('linux') |
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
157 | 158 |
158 def postprocess_iteration(self): | 159 def postprocess_iteration(self): |
159 self.generate_keyval() | 160 self.generate_keyval() |
160 if self.auto_mode: | 161 if self.auto_mode: |
161 a = postprocessing.IOzoneAnalyzer(list_files=[self.results_path], | 162 a = postprocessing.IOzoneAnalyzer(list_files=[self.results_path], |
162 output_dir=self.analysisdir) | 163 output_dir=self.analysisdir) |
163 a.analyze() | 164 a.analyze() |
164 p = postprocessing.IOzonePlotter(results_file=self.results_path, | 165 p = postprocessing.IOzonePlotter(results_file=self.results_path, |
165 output_dir=self.analysisdir) | 166 output_dir=self.analysisdir) |
166 p.plot_all() | 167 p.plot_all() |
OLD | NEW |