Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(227)

Side by Side Diff: net/disk_cache/simple/simple_experiment.h

Issue 2918893002: evict larger entries first (Closed)
Patch Set: update experiment param Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef NET_DISK_CACHE_SIMPLE_SIMPLE_EXPERIMENT_H_ 5 #ifndef NET_DISK_CACHE_SIMPLE_SIMPLE_EXPERIMENT_H_
6 #define NET_DISK_CACHE_SIMPLE_SIMPLE_EXPERIMENT_H_ 6 #define NET_DISK_CACHE_SIMPLE_SIMPLE_EXPERIMENT_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/feature_list.h" 10 #include "base/feature_list.h"
11 #include "net/base/cache_type.h" 11 #include "net/base/cache_type.h"
12 #include "net/base/net_export.h" 12 #include "net/base/net_export.h"
13 13
14 namespace disk_cache { 14 namespace disk_cache {
15 15
16 NET_EXPORT_PRIVATE extern const base::Feature kSimpleSizeExperiment; 16 NET_EXPORT_PRIVATE extern const base::Feature kSimpleSizeExperiment;
17 NET_EXPORT_PRIVATE extern const base::Feature kSimpleCacheEvictionWithSize;
17 NET_EXPORT_PRIVATE extern const char kSizeMultiplierParam[]; 18 NET_EXPORT_PRIVATE extern const char kSizeMultiplierParam[];
18 19
19 // This lists the experiment groups for SimpleCache. Only add new groups at 20 // This lists the experiment groups for SimpleCache. Only add new groups at
20 // the end of the list, and always increase the number. 21 // the end of the list, and always increase the number.
21 enum class SimpleExperimentType : uint32_t { 22 enum class SimpleExperimentType : uint32_t {
22 NONE = 0, 23 NONE = 0,
23 SIZE = 1, 24 SIZE = 1,
25 EVICT_WITH_SIZE = 2,
24 }; 26 };
25 27
26 struct NET_EXPORT_PRIVATE SimpleExperiment { 28 struct NET_EXPORT_PRIVATE SimpleExperiment {
27 SimpleExperimentType type = SimpleExperimentType::NONE; 29 SimpleExperimentType type = SimpleExperimentType::NONE;
28 uint32_t param = 0; 30 uint32_t param = 0;
29 }; 31 };
30 32
31 NET_EXPORT_PRIVATE SimpleExperiment 33 NET_EXPORT_PRIVATE SimpleExperiment
32 GetSimpleExperiment(net::CacheType cache_type); 34 GetSimpleExperiment(net::CacheType cache_type);
33 35
34 } // namespace disk_cache 36 } // namespace disk_cache
35 37
36 #endif // NET_DISK_CACHE_SIMPLE_SIMPLE_EXPERIMENT_H_ 38 #endif // NET_DISK_CACHE_SIMPLE_SIMPLE_EXPERIMENT_H_
OLDNEW
« no previous file with comments | « no previous file | net/disk_cache/simple/simple_experiment.cc » ('j') | net/disk_cache/simple/simple_index.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698