diff options
author | eroman@chromium.org <eroman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-02-14 01:12:12 +0000 |
---|---|---|
committer | eroman@chromium.org <eroman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-02-14 01:12:12 +0000 |
commit | 2149cc62fd9464cf80b427c0acd022ff5d7b03b5 (patch) | |
tree | 9da50d5c466a5f52d00aa94e9319870b40011cc6 /base/compiler_specific.h | |
parent | 00cd54b939d7498ddc2e5ae355a03250f13b35d7 (diff) | |
download | chromium_src-2149cc62fd9464cf80b427c0acd022ff5d7b03b5.zip chromium_src-2149cc62fd9464cf80b427c0acd022ff5d7b03b5.tar.gz chromium_src-2149cc62fd9464cf80b427c0acd022ff5d7b03b5.tar.bz2 |
Add a stackframe named 'CrashIntentionally' to crashes from about:crash.
This should make it easier to categorize on the crash server.
BUG=113231
Review URL: http://codereview.chromium.org/9380026
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@121798 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/compiler_specific.h')
-rw-r--r-- | base/compiler_specific.h | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/base/compiler_specific.h b/base/compiler_specific.h index 99c38ce..0d93460 100644 --- a/base/compiler_specific.h +++ b/base/compiler_specific.h @@ -1,4 +1,4 @@ -// Copyright (c) 2011 The Chromium Authors. All rights reserved. +// Copyright (c) 2012 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. @@ -90,9 +90,18 @@ // int x ALLOW_UNUSED = ...; #if defined(COMPILER_GCC) #define ALLOW_UNUSED __attribute__((unused)) -#define NOINLINE __attribute__((noinline)) #else #define ALLOW_UNUSED +#endif + +// Annotate a function indicating it should not be inlined. +// Use like: +// NOINLINE void DoStuff() { ... } +#if defined(COMPILER_GCC) +#define NOINLINE __attribute__((noinline)) +#elif defined(COMPILER_MSVC) +#define NOINLINE __declspec(noinline) +#else #define NOINLINE #endif |