| OLD | NEW |
| 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2012 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 268 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 279 | 279 |
| 280 Valgrind for Mac OS X requires that debugging information be in a .dSYM | 280 Valgrind for Mac OS X requires that debugging information be in a .dSYM |
| 281 bundle generated by dsymutil. It is not currently able to chase DWARF | 281 bundle generated by dsymutil. It is not currently able to chase DWARF |
| 282 data into .o files like gdb does, so executables without .dSYM bundles or | 282 data into .o files like gdb does, so executables without .dSYM bundles or |
| 283 with the Chromium-specific "fake_dsym" bundles generated by | 283 with the Chromium-specific "fake_dsym" bundles generated by |
| 284 build/mac/strip_save_dsym won't give source file and line number | 284 build/mac/strip_save_dsym won't give source file and line number |
| 285 information in valgrind. | 285 information in valgrind. |
| 286 | 286 |
| 287 This function will run dsymutil if the .dSYM bundle is missing or if | 287 This function will run dsymutil if the .dSYM bundle is missing or if |
| 288 it looks like a fake_dsym. A non-fake dsym that already exists is assumed | 288 it looks like a fake_dsym. A non-fake dsym that already exists is assumed |
| 289 to be up-to-date. | 289 to be up to date. |
| 290 """ | 290 """ |
| 291 test_command = self._args[0] | 291 test_command = self._args[0] |
| 292 dsym_bundle = self._args[0] + '.dSYM' | 292 dsym_bundle = self._args[0] + '.dSYM' |
| 293 dsym_file = os.path.join(dsym_bundle, 'Contents', 'Resources', 'DWARF', | 293 dsym_file = os.path.join(dsym_bundle, 'Contents', 'Resources', 'DWARF', |
| 294 os.path.basename(test_command)) | 294 os.path.basename(test_command)) |
| 295 dsym_info_plist = os.path.join(dsym_bundle, 'Contents', 'Info.plist') | 295 dsym_info_plist = os.path.join(dsym_bundle, 'Contents', 'Info.plist') |
| 296 | 296 |
| 297 needs_dsymutil = True | 297 needs_dsymutil = True |
| 298 saved_test_command = None | 298 saved_test_command = None |
| 299 | 299 |
| (...skipping 537 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 837 return DrMemory(False, True) | 837 return DrMemory(False, True) |
| 838 try: | 838 try: |
| 839 platform_name = common.PlatformNames()[0] | 839 platform_name = common.PlatformNames()[0] |
| 840 except common.NotImplementedError: | 840 except common.NotImplementedError: |
| 841 platform_name = sys.platform + "(Unknown)" | 841 platform_name = sys.platform + "(Unknown)" |
| 842 raise RuntimeError, "Unknown tool (tool=%s, platform=%s)" % (tool_name, | 842 raise RuntimeError, "Unknown tool (tool=%s, platform=%s)" % (tool_name, |
| 843 platform_name) | 843 platform_name) |
| 844 | 844 |
| 845 def CreateTool(tool): | 845 def CreateTool(tool): |
| 846 return ToolFactory().Create(tool) | 846 return ToolFactory().Create(tool) |
| OLD | NEW |