summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSiddhesh Poyarekar <siddhesh@sourceware.org>2021-02-03 20:03:19 +0530
committerSiddhesh Poyarekar <siddhesh@sourceware.org>2021-02-10 19:08:33 +0530
commita1b8b06a55c1ee581d5ef860cec214b0c27a66f0 (patch)
tree2e402d17246be7a81ed877c08e135afe559875c9
parent61117bfa1b08ca048e6512c0652c568300fedf6a (diff)
downloadglibc-a1b8b06a55c1ee581d5ef860cec214b0c27a66f0.tar.gz
x86: Use SIZE_MAX instead of (long int)-1 for tunable range value
The tunable types are SIZE_T, so set the ranges to the correct maximum value, i.e. SIZE_MAX.
-rw-r--r--sysdeps/x86/dl-cacheinfo.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/sysdeps/x86/dl-cacheinfo.h b/sysdeps/x86/dl-cacheinfo.h
index e5d23e676e..f3de206dc1 100644
--- a/sysdeps/x86/dl-cacheinfo.h
+++ b/sysdeps/x86/dl-cacheinfo.h
@@ -929,14 +929,14 @@ dl_init_cacheinfo (struct cpu_features *cpu_features)
rep_stosb_threshold = TUNABLE_GET (x86_rep_stosb_threshold,
long int, NULL);
- TUNABLE_SET_WITH_BOUNDS (x86_data_cache_size, data, 0, (long int) -1);
- TUNABLE_SET_WITH_BOUNDS (x86_shared_cache_size, shared, 0, (long int) -1);
+ TUNABLE_SET_WITH_BOUNDS (x86_data_cache_size, data, 0, SIZE_MAX);
+ TUNABLE_SET_WITH_BOUNDS (x86_shared_cache_size, shared, 0, SIZE_MAX);
TUNABLE_SET_WITH_BOUNDS (x86_non_temporal_threshold, non_temporal_threshold,
- 0, (long int) -1);
+ 0, SIZE_MAX);
TUNABLE_SET_WITH_BOUNDS (x86_rep_movsb_threshold, rep_movsb_threshold,
- minimum_rep_movsb_threshold, (long int) -1);
+ minimum_rep_movsb_threshold, SIZE_MAX);
TUNABLE_SET_WITH_BOUNDS (x86_rep_stosb_threshold, rep_stosb_threshold, 1,
- (long int) -1);
+ SIZE_MAX);
#endif
cpu_features->data_cache_size = data;