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

Side by Side Diff: test/cctest/test-run-wasm-relocation-ia32.cc

Issue 1847543002: Expose a lower bound of malloc'd memory via heap statistics (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: updates Created 4 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
« no previous file with comments | « test/cctest/test-regexp.cc ('k') | test/cctest/test-run-wasm-relocation-x87.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 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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 #include <stdlib.h> 5 #include <stdlib.h>
6 6
7 #include "src/v8.h" 7 #include "src/v8.h"
8 8
9 #include "src/debug/debug.h" 9 #include "src/debug/debug.h"
10 #include "src/disasm.h" 10 #include "src/disasm.h"
11 #include "src/disassembler.h" 11 #include "src/disassembler.h"
12 #include "src/ia32/frames-ia32.h" 12 #include "src/ia32/frames-ia32.h"
13 #include "src/ic/ic.h" 13 #include "src/ic/ic.h"
14 #include "src/macro-assembler.h" 14 #include "src/macro-assembler.h"
15 #include "test/cctest/cctest.h" 15 #include "test/cctest/cctest.h"
16 #include "test/cctest/compiler/c-signature.h" 16 #include "test/cctest/compiler/c-signature.h"
17 #include "test/cctest/compiler/call-tester.h" 17 #include "test/cctest/compiler/call-tester.h"
18 18
19 using namespace v8::internal; 19 using namespace v8::internal;
20 using namespace v8::internal::compiler; 20 using namespace v8::internal::compiler;
21 21
22 #define __ assm. 22 #define __ assm.
23 23
24 static int32_t DummyStaticFunction(Object* result) { return 1; } 24 static int32_t DummyStaticFunction(Object* result) { return 1; }
25 25
26 TEST(WasmRelocationIa32) { 26 TEST(WasmRelocationIa32) {
27 CcTest::InitializeVM(); 27 CcTest::InitializeVM();
28 Zone zone;
29 Isolate* isolate = CcTest::i_isolate(); 28 Isolate* isolate = CcTest::i_isolate();
29 Zone zone(isolate->allocator());
30 HandleScope scope(isolate); 30 HandleScope scope(isolate);
31 v8::internal::byte buffer[4096]; 31 v8::internal::byte buffer[4096];
32 Assembler assm(isolate, buffer, sizeof buffer); 32 Assembler assm(isolate, buffer, sizeof buffer);
33 DummyStaticFunction(NULL); 33 DummyStaticFunction(NULL);
34 int32_t imm = 1234567; 34 int32_t imm = 1234567;
35 35
36 __ mov(eax, Immediate(reinterpret_cast<Address>(imm), 36 __ mov(eax, Immediate(reinterpret_cast<Address>(imm),
37 RelocInfo::WASM_MEMORY_REFERENCE)); 37 RelocInfo::WASM_MEMORY_REFERENCE));
38 __ nop(); 38 __ nop();
39 __ ret(0); 39 __ ret(0);
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 #ifdef OBJECT_PRINT 80 #ifdef OBJECT_PRINT
81 // OFStream os(stdout); 81 // OFStream os(stdout);
82 code->Print(os); 82 code->Print(os);
83 begin = code->instruction_start(); 83 begin = code->instruction_start();
84 end = begin + code->instruction_size(); 84 end = begin + code->instruction_size();
85 disasm::Disassembler::Disassemble(stdout, begin, end); 85 disasm::Disassembler::Disassemble(stdout, begin, end);
86 #endif 86 #endif
87 } 87 }
88 88
89 #undef __ 89 #undef __
OLDNEW
« no previous file with comments | « test/cctest/test-regexp.cc ('k') | test/cctest/test-run-wasm-relocation-x87.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698