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

Side by Side Diff: test/cctest/trace-extension.cc

Issue 2001073002: [build] Fix a clang warning (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebase Created 4 years, 7 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-reloc-info.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 CHECK_EQ(2, args.Length()); // Ignore second argument on 32-bit platform. 79 CHECK_EQ(2, args.Length()); // Ignore second argument on 32-bit platform.
80 #if defined(V8_HOST_ARCH_32_BIT) 80 #if defined(V8_HOST_ARCH_32_BIT)
81 Address fp = *reinterpret_cast<Address*>(*args[0]); 81 Address fp = *reinterpret_cast<Address*>(*args[0]);
82 #elif defined(V8_HOST_ARCH_64_BIT) 82 #elif defined(V8_HOST_ARCH_64_BIT)
83 int64_t low_bits = *reinterpret_cast<uint64_t*>(*args[0]) >> 32; 83 int64_t low_bits = *reinterpret_cast<uint64_t*>(*args[0]) >> 32;
84 int64_t high_bits = *reinterpret_cast<uint64_t*>(*args[1]); 84 int64_t high_bits = *reinterpret_cast<uint64_t*>(*args[1]);
85 Address fp = reinterpret_cast<Address>(high_bits | low_bits); 85 Address fp = reinterpret_cast<Address>(high_bits | low_bits);
86 #else 86 #else
87 #error Host architecture is neither 32-bit nor 64-bit. 87 #error Host architecture is neither 32-bit nor 64-bit.
88 #endif 88 #endif
89 printf("Trace: %p\n", fp); 89 printf("Trace: %p\n", static_cast<void*>(fp));
90 return fp; 90 return fp;
91 } 91 }
92 92
93 93
94 static struct { 94 static struct {
95 TickSample* sample; 95 TickSample* sample;
96 } trace_env = { NULL }; 96 } trace_env = { NULL };
97 97
98 98
99 void TraceExtension::InitTraceEnv(TickSample* sample) { 99 void TraceExtension::InitTraceEnv(TickSample* sample) {
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
161 v8::HandleScope scope(args.GetIsolate()); 161 v8::HandleScope scope(args.GetIsolate());
162 const Address js_entry_sp = GetJsEntrySp(); 162 const Address js_entry_sp = GetJsEntrySp();
163 CHECK(js_entry_sp); 163 CHECK(js_entry_sp);
164 CompileRun("js_entry_sp();"); 164 CompileRun("js_entry_sp();");
165 CHECK_EQ(js_entry_sp, GetJsEntrySp()); 165 CHECK_EQ(js_entry_sp, GetJsEntrySp());
166 } 166 }
167 167
168 168
169 } // namespace internal 169 } // namespace internal
170 } // namespace v8 170 } // namespace v8
OLDNEW
« no previous file with comments | « test/cctest/test-reloc-info.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698