Lines Matching refs:V8
1 // Copyright 2008 the V8 project authors. All rights reserved.
28 #include "v8.h"
37 v8::Locker locker;
38 v8::V8::Initialize();
39 v8::HandleScope scope;
40 v8::Context::Scope context_scope(v8::Context::New());
42 v8::Locker::StartPreemption(100);
44 v8::Handle<v8::Script> script = v8::Script::Compile(
45 v8::String::New("var count = 0; var obj = new Object(); count++;\n"));
49 v8::Locker::StopPreemption();
50 v8::internal::OS::Sleep(500); // Make sure the timer fires.
66 class ThreadA : public v8::internal::Thread {
70 v8::Locker locker;
71 v8::HandleScope scope;
72 v8::Context::Scope context_scope(v8::Context::New());
77 v8::Handle<v8::Script> script = v8::Script::Compile(
78 v8::String::New(
89 v8::Unlocker unlocker;
102 class ThreadB : public v8::internal::Thread {
108 v8::Locker locker;
110 v8::HandleScope scope;
111 v8::Context::Scope context_scope(v8::Context::New());
114 HEAP->CollectAllGarbage(v8::internal::Heap::kNoGCFlags);
127 v8::V8::Initialize();
141 class ThreadIdValidationThread : public v8::internal::Thread {
195 class ThreadC : public v8::internal::Thread {