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

Side by Side Diff: test/cctest/cctest.cc

Issue 2371833007: [wasm] Initial signal handler (Closed)
Patch Set: Make sure guard pages get set up when resizing from 0 to more than 0 Created 3 years, 9 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 | « src/wasm/wasm-module.cc ('k') | test/cctest/wasm/test-wasm-trap-position.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 2008 the V8 project authors. All rights reserved. 1 // Copyright 2008 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 13 matching lines...) Expand all
24 // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 24 // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 25 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
26 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 26 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27 27
28 #include "include/v8.h" 28 #include "include/v8.h"
29 #include "test/cctest/cctest.h" 29 #include "test/cctest/cctest.h"
30 30
31 #include "include/libplatform/libplatform.h" 31 #include "include/libplatform/libplatform.h"
32 #include "src/debug/debug.h" 32 #include "src/debug/debug.h"
33 #include "src/objects-inl.h" 33 #include "src/objects-inl.h"
34 #include "src/trap-handler/trap-handler.h"
34 #include "test/cctest/print-extension.h" 35 #include "test/cctest/print-extension.h"
35 #include "test/cctest/profiler-extension.h" 36 #include "test/cctest/profiler-extension.h"
36 #include "test/cctest/trace-extension.h" 37 #include "test/cctest/trace-extension.h"
37 38
38 #if V8_OS_WIN 39 #if V8_OS_WIN
39 #include <windows.h> // NOLINT 40 #include <windows.h> // NOLINT
40 #if V8_CC_MSVC 41 #if V8_CC_MSVC
41 #include <crtdbg.h> 42 #include <crtdbg.h>
42 #endif 43 #endif
43 #endif 44 #endif
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
261 } 262 }
262 } 263 }
263 264
264 v8::V8::InitializeICUDefaultLocation(argv[0]); 265 v8::V8::InitializeICUDefaultLocation(argv[0]);
265 v8::Platform* platform = v8::platform::CreateDefaultPlatform(); 266 v8::Platform* platform = v8::platform::CreateDefaultPlatform();
266 v8::V8::InitializePlatform(platform); 267 v8::V8::InitializePlatform(platform);
267 v8::internal::FlagList::SetFlagsFromCommandLine(&argc, argv, true); 268 v8::internal::FlagList::SetFlagsFromCommandLine(&argc, argv, true);
268 v8::V8::Initialize(); 269 v8::V8::Initialize();
269 v8::V8::InitializeExternalStartupData(argv[0]); 270 v8::V8::InitializeExternalStartupData(argv[0]);
270 271
272 if (i::trap_handler::UseTrapHandler()) {
273 v8::V8::RegisterDefaultSignalHandler();
274 }
275
271 CcTestArrayBufferAllocator array_buffer_allocator; 276 CcTestArrayBufferAllocator array_buffer_allocator;
272 CcTest::set_array_buffer_allocator(&array_buffer_allocator); 277 CcTest::set_array_buffer_allocator(&array_buffer_allocator);
273 278
274 i::PrintExtension print_extension; 279 i::PrintExtension print_extension;
275 v8::RegisterExtension(&print_extension); 280 v8::RegisterExtension(&print_extension);
276 i::ProfilerExtension profiler_extension; 281 i::ProfilerExtension profiler_extension;
277 v8::RegisterExtension(&profiler_extension); 282 v8::RegisterExtension(&profiler_extension);
278 i::TraceExtension trace_extension; 283 i::TraceExtension trace_extension;
279 v8::RegisterExtension(&trace_extension); 284 v8::RegisterExtension(&trace_extension);
280 285
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
328 CcTest::TearDown(); 333 CcTest::TearDown();
329 // TODO(svenpanne) See comment above. 334 // TODO(svenpanne) See comment above.
330 // if (!disable_automatic_dispose_) v8::V8::Dispose(); 335 // if (!disable_automatic_dispose_) v8::V8::Dispose();
331 v8::V8::ShutdownPlatform(); 336 v8::V8::ShutdownPlatform();
332 delete platform; 337 delete platform;
333 return 0; 338 return 0;
334 } 339 }
335 340
336 RegisterThreadedTest *RegisterThreadedTest::first_ = NULL; 341 RegisterThreadedTest *RegisterThreadedTest::first_ = NULL;
337 int RegisterThreadedTest::count_ = 0; 342 int RegisterThreadedTest::count_ = 0;
OLDNEW
« no previous file with comments | « src/wasm/wasm-module.cc ('k') | test/cctest/wasm/test-wasm-trap-position.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698