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

Side by Side Diff: base/allocator/BUILD.gn

Issue 2793793002: Fix -Wshift-negative-value transgression in tcmalloc. (Closed)
Patch Set: Created 3 years, 8 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 (c) 2013 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2013 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 import("//build/buildflag_header.gni") 5 import("//build/buildflag_header.gni")
6 import("//build/config/allocator.gni") 6 import("//build/config/allocator.gni")
7 import("//build/config/compiler/compiler.gni") 7 import("//build/config/compiler/compiler.gni")
8 8
9 declare_args() { 9 declare_args() {
10 # Provide a way to force disable debugallocation in Debug builds, 10 # Provide a way to force disable debugallocation in Debug builds,
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 defines += [ "TCMALLOC_DONT_REPLACE_SYSTEM_ALLOC" ] 58 defines += [ "TCMALLOC_DONT_REPLACE_SYSTEM_ALLOC" ]
59 } 59 }
60 if (is_clang) { 60 if (is_clang) {
61 cflags = [ 61 cflags = [
62 # tcmalloc initializes some fields in the wrong order. 62 # tcmalloc initializes some fields in the wrong order.
63 "-Wno-reorder", 63 "-Wno-reorder",
64 64
65 # tcmalloc contains some unused local template specializations. 65 # tcmalloc contains some unused local template specializations.
66 "-Wno-unused-function", 66 "-Wno-unused-function",
67 67
68 # tcmalloc uses COMPILE_ASSERT without static_assert but with 68 # tcmalloc uses COMPILE_ASSERT without static_assert but with typedefs.
69 # typedefs.
70 "-Wno-unused-local-typedefs", 69 "-Wno-unused-local-typedefs",
71 70
72 # for magic2_ in debugallocation.cc (only built in Debug builds) 71 # for magic2_ in debugallocation.cc (only built in Debug builds) typedefs.
73 # typedefs.
74 "-Wno-unused-private-field", 72 "-Wno-unused-private-field",
75
76 # base/basictypes.h's kint64min definition shifts a negative value around,
77 # which is undefined behavior. TODO(thakis): Try to get that fixed.
78 "-Wno-shift-negative-value",
79 ] 73 ]
80 } else { 74 } else {
81 cflags = [] 75 cflags = []
82 } 76 }
83 77
84 if (is_linux || is_android) { 78 if (is_linux || is_android) {
85 # We enable all warnings by default, but upstream disables a few. 79 # We enable all warnings by default, but upstream disables a few.
86 # Keep "-Wno-*" flags in sync with upstream by comparing against: 80 # Keep "-Wno-*" flags in sync with upstream by comparing against:
87 # http://code.google.com/p/google-perftools/source/browse/trunk/Makefile.am 81 # http://code.google.com/p/google-perftools/source/browse/trunk/Makefile.am
88 cflags += [ 82 cflags += [
(...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after
309 "-Wl,-wrap,calloc", 303 "-Wl,-wrap,calloc",
310 "-Wl,-wrap,free", 304 "-Wl,-wrap,free",
311 "-Wl,-wrap,malloc", 305 "-Wl,-wrap,malloc",
312 "-Wl,-wrap,memalign", 306 "-Wl,-wrap,memalign",
313 "-Wl,-wrap,posix_memalign", 307 "-Wl,-wrap,posix_memalign",
314 "-Wl,-wrap,pvalloc", 308 "-Wl,-wrap,pvalloc",
315 "-Wl,-wrap,realloc", 309 "-Wl,-wrap,realloc",
316 "-Wl,-wrap,valloc", 310 "-Wl,-wrap,valloc",
317 ] 311 ]
318 } 312 }
OLDNEW
« no previous file with comments | « no previous file | third_party/tcmalloc/README.chromium » ('j') | third_party/tcmalloc/chromium/src/base/basictypes.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698