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

Side by Side Diff: src/allocation.h

Issue 2416243002: Make unittests work in component build (Closed)
Patch Set: updates Created 4 years, 2 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
« no previous file with comments | « no previous file | src/asmjs/asm-types.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project 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 V8_ALLOCATION_H_ 5 #ifndef V8_ALLOCATION_H_
6 #define V8_ALLOCATION_H_ 6 #define V8_ALLOCATION_H_
7 7
8 #include "src/base/compiler-specific.h"
8 #include "src/globals.h" 9 #include "src/globals.h"
9 10
10 namespace v8 { 11 namespace v8 {
11 namespace internal { 12 namespace internal {
12 13
13 // Called when allocation routines fail to allocate. 14 // Called when allocation routines fail to allocate.
14 // This function should not return, but should terminate the current 15 // This function should not return, but should terminate the current
15 // processing. 16 // processing.
16 V8_EXPORT_PRIVATE void FatalProcessOutOfMemory(const char* message); 17 V8_EXPORT_PRIVATE void FatalProcessOutOfMemory(const char* message);
17 18
(...skipping 14 matching lines...) Expand all
32 // In release mode we are not willing to pay this overhead. 33 // In release mode we are not willing to pay this overhead.
33 34
34 #ifdef DEBUG 35 #ifdef DEBUG
35 // Superclass for classes with instances allocated inside stack 36 // Superclass for classes with instances allocated inside stack
36 // activations or inside other objects. 37 // activations or inside other objects.
37 class Embedded { 38 class Embedded {
38 public: 39 public:
39 void* operator new(size_t size); 40 void* operator new(size_t size);
40 void operator delete(void* p); 41 void operator delete(void* p);
41 }; 42 };
42 #define BASE_EMBEDDED : public Embedded 43 #define BASE_EMBEDDED : public NON_EXPORTED_BASE(Embedded)
43 #else 44 #else
44 #define BASE_EMBEDDED 45 #define BASE_EMBEDDED
45 #endif 46 #endif
46 47
47 48
48 // Superclass for classes only using static method functions. 49 // Superclass for classes only using static method functions.
49 // The subclass of AllStatic cannot be instantiated at all. 50 // The subclass of AllStatic cannot be instantiated at all.
50 class AllStatic { 51 class AllStatic {
51 #ifdef DEBUG 52 #ifdef DEBUG
52 public: 53 public:
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 }; 86 };
86 87
87 88
88 void* AlignedAlloc(size_t size, size_t alignment); 89 void* AlignedAlloc(size_t size, size_t alignment);
89 void AlignedFree(void *ptr); 90 void AlignedFree(void *ptr);
90 91
91 } // namespace internal 92 } // namespace internal
92 } // namespace v8 93 } // namespace v8
93 94
94 #endif // V8_ALLOCATION_H_ 95 #endif // V8_ALLOCATION_H_
OLDNEW
« no previous file with comments | « no previous file | src/asmjs/asm-types.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698