OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CHROME_BROWSER_FRAGMENTATION_CHECKER_WIN_H_ |
| 6 #define CHROME_BROWSER_FRAGMENTATION_CHECKER_WIN_H_ |
| 7 #pragma once |
| 8 |
| 9 class FilePath; |
| 10 |
| 11 namespace fragmentation_checker { |
| 12 |
| 13 const int kMaxExtentCount = 1 << 16; |
| 14 |
| 15 // Returns the number of extents for the file at |file_path|. The number is |
| 16 // capped at kMaxExtentCount, files with more extents than that will be counted |
| 17 // as having kMaxExtentCount extents. On failure, this function returns 0. |
| 18 int CountFileExtents(const FilePath& file_path); |
| 19 |
| 20 // Records fragmentation metrics for the current module. This records the number |
| 21 // of fragments the current module is stored in. |
| 22 // This will be used to determine whether pursuing more aggressive |
| 23 // manual defragmentation is worth the effort. |
| 24 void RecordFragmentationMetricForCurrentModule(); |
| 25 |
| 26 } // namespace fragmentation_checker |
| 27 |
| 28 #endif // CHROME_BROWSER_FRAGMENTATION_CHECKER_WIN_H_ |
OLD | NEW |