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

Side by Side Diff: runtime/vm/virtual_memory_test.cc

Issue 9189003: Move assert.h/assert.cc from runtime/vm to runtime/platform (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Check for correct rebase Created 8 years, 11 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 | Annotate | Revision Log
« no previous file with comments | « runtime/vm/virtual_memory_macos.cc ('k') | runtime/vm/virtual_memory_win.cc » ('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 (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/assert.h" 5 #include "platform/assert.h"
6 #include "vm/unit_test.h" 6 #include "vm/unit_test.h"
7 #include "vm/virtual_memory.h" 7 #include "vm/virtual_memory.h"
8 8
9 namespace dart { 9 namespace dart {
10 10
11 UNIT_TEST_CASE(AllocateVirtualMemory) { 11 UNIT_TEST_CASE(AllocateVirtualMemory) {
12 const intptr_t kVirtualMemoryBlockSize = 64 * KB; 12 const intptr_t kVirtualMemoryBlockSize = 64 * KB;
13 VirtualMemory* vm = VirtualMemory::Reserve(kVirtualMemoryBlockSize); 13 VirtualMemory* vm = VirtualMemory::Reserve(kVirtualMemoryBlockSize);
14 EXPECT(vm != NULL); 14 EXPECT(vm != NULL);
15 EXPECT(vm->address() != NULL); 15 EXPECT(vm->address() != NULL);
(...skipping 22 matching lines...) Expand all
38 38
39 delete vm; 39 delete vm;
40 40
41 const intptr_t kAlignment = 1 * MB; 41 const intptr_t kAlignment = 1 * MB;
42 vm = VirtualMemory::ReserveAligned(kVirtualMemoryBlockSize, kAlignment); 42 vm = VirtualMemory::ReserveAligned(kVirtualMemoryBlockSize, kAlignment);
43 ASSERT((vm->start() & (kAlignment - 1)) == 0); 43 ASSERT((vm->start() & (kAlignment - 1)) == 0);
44 delete vm; 44 delete vm;
45 } 45 }
46 46
47 } // namespace dart 47 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/virtual_memory_macos.cc ('k') | runtime/vm/virtual_memory_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698