OLD | NEW |
1 # Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 """Runs an exe through Valgrind and puts the intermediate files in a | 5 """Runs an exe through Valgrind and puts the intermediate files in a |
6 directory. | 6 directory. |
7 """ | 7 """ |
8 | 8 |
9 import datetime | 9 import datetime |
10 import glob | 10 import glob |
(...skipping 810 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
821 logging.info("Excluding python children") | 821 logging.info("Excluding python children") |
822 drconfig_cmd += ["-reg", "python.exe", "-norun"] | 822 drconfig_cmd += ["-reg", "python.exe", "-norun"] |
823 if run_drconfig: | 823 if run_drconfig: |
824 drconfig_retcode = common.RunSubprocess(drconfig_cmd, self._timeout) | 824 drconfig_retcode = common.RunSubprocess(drconfig_cmd, self._timeout) |
825 if drconfig_retcode: | 825 if drconfig_retcode: |
826 logging.error("Configuring whether to follow python children failed " \ | 826 logging.error("Configuring whether to follow python children failed " \ |
827 "with %d.", drconfig_retcode) | 827 "with %d.", drconfig_retcode) |
828 raise RuntimeError, "Configuring python children failed " | 828 raise RuntimeError, "Configuring python children failed " |
829 | 829 |
830 suppression_count = 0 | 830 suppression_count = 0 |
831 for suppression_file in self._options.suppressions: | 831 supp_files = self._options.suppressions |
| 832 if self.handle_uninits_and_leaks: |
| 833 supp_files += [s.replace(".txt", "_full.txt") for s in supp_files] |
| 834 for suppression_file in supp_files: |
832 if os.path.exists(suppression_file): | 835 if os.path.exists(suppression_file): |
833 suppression_count += 1 | 836 suppression_count += 1 |
834 proc += ["-suppress", common.NormalizeWindowsPath(suppression_file)] | 837 proc += ["-suppress", common.NormalizeWindowsPath(suppression_file)] |
835 | 838 |
836 if not suppression_count: | 839 if not suppression_count: |
837 logging.warning("WARNING: NOT USING SUPPRESSIONS!") | 840 logging.warning("WARNING: NOT USING SUPPRESSIONS!") |
838 | 841 |
839 # Un-comment to dump Dr.Memory events on error | 842 # Un-comment to dump Dr.Memory events on error |
840 #proc += ["-dr_ops", "-dumpcore_mask 0x8bff"] | 843 #proc += ["-dr_ops", "-dumpcore_mask 0x8bff"] |
841 | 844 |
(...skipping 350 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1192 return Asan() | 1195 return Asan() |
1193 try: | 1196 try: |
1194 platform_name = common.PlatformNames()[0] | 1197 platform_name = common.PlatformNames()[0] |
1195 except common.NotImplementedError: | 1198 except common.NotImplementedError: |
1196 platform_name = sys.platform + "(Unknown)" | 1199 platform_name = sys.platform + "(Unknown)" |
1197 raise RuntimeError, "Unknown tool (tool=%s, platform=%s)" % (tool_name, | 1200 raise RuntimeError, "Unknown tool (tool=%s, platform=%s)" % (tool_name, |
1198 platform_name) | 1201 platform_name) |
1199 | 1202 |
1200 def CreateTool(tool): | 1203 def CreateTool(tool): |
1201 return ToolFactory().Create(tool) | 1204 return ToolFactory().Create(tool) |
OLD | NEW |