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

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

Issue 2063303002: Fix product build (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 6 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 | « runtime/vm/object.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 (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, 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/service_isolate.h" 5 #include "vm/service_isolate.h"
6 6
7 #include "vm/compiler.h" 7 #include "vm/compiler.h"
8 #include "vm/dart_api_impl.h" 8 #include "vm/dart_api_impl.h"
9 #include "vm/dart_entry.h" 9 #include "vm/dart_entry.h"
10 #include "vm/dev_fs.h" 10 #include "vm/dev_fs.h"
(...skipping 440 matching lines...) Expand 10 before | Expand all | Expand 10 after
451 }; 451 };
452 452
453 453
454 void ServiceIsolate::Run() { 454 void ServiceIsolate::Run() {
455 ASSERT(monitor_ == NULL); 455 ASSERT(monitor_ == NULL);
456 monitor_ = new Monitor(); 456 monitor_ = new Monitor();
457 ASSERT(monitor_ != NULL); 457 ASSERT(monitor_ != NULL);
458 // Grab the isolate create callback here to avoid race conditions with tests 458 // Grab the isolate create callback here to avoid race conditions with tests
459 // that change this after Dart_Initialize returns. 459 // that change this after Dart_Initialize returns.
460 create_callback_ = Isolate::CreateCallback(); 460 create_callback_ = Isolate::CreateCallback();
461 DevFS::Init(); 461 if (FLAG_support_service) {
462 DevFS::Init();
463 }
462 Dart::thread_pool()->Run(new RunServiceTask()); 464 Dart::thread_pool()->Run(new RunServiceTask());
463 } 465 }
464 466
465 467
466 void ServiceIsolate::KillServiceIsolate() { 468 void ServiceIsolate::KillServiceIsolate() {
467 if (!FLAG_shutdown) { 469 if (!FLAG_shutdown) {
468 return; 470 return;
469 } 471 }
470 { 472 {
471 MonitorLocker ml(monitor_); 473 MonitorLocker ml(monitor_);
(...skipping 28 matching lines...) Expand all
500 // the VMService object and set up its shutdown handler in the service 502 // the VMService object and set up its shutdown handler in the service
501 // isolate's main() function, this case will no longer be possible and 503 // isolate's main() function, this case will no longer be possible and
502 // can be removed. 504 // can be removed.
503 KillServiceIsolate(); 505 KillServiceIsolate();
504 } 506 }
505 } 507 }
506 if (server_address_ != NULL) { 508 if (server_address_ != NULL) {
507 free(server_address_); 509 free(server_address_);
508 server_address_ = NULL; 510 server_address_ = NULL;
509 } 511 }
510 DevFS::Cleanup(); 512 if (FLAG_support_service) {
513 DevFS::Cleanup();
514 }
511 } 515 }
512 516
513 517
514 void ServiceIsolate::BootVmServiceLibrary() { 518 void ServiceIsolate::BootVmServiceLibrary() {
515 Thread* thread = Thread::Current(); 519 Thread* thread = Thread::Current();
516 const Library& vmservice_library = 520 const Library& vmservice_library =
517 Library::Handle(Library::LookupLibrary(thread, Symbols::DartVMService())); 521 Library::Handle(Library::LookupLibrary(thread, Symbols::DartVMService()));
518 ASSERT(!vmservice_library.IsNull()); 522 ASSERT(!vmservice_library.IsNull());
519 const String& boot_function_name = String::Handle(String::New("boot")); 523 const String& boot_function_name = String::Handle(String::New("boot"));
520 const Function& boot_function = 524 const Function& boot_function =
(...skipping 10 matching lines...) Expand all
531 } 535 }
532 ASSERT(port != ILLEGAL_PORT); 536 ASSERT(port != ILLEGAL_PORT);
533 ServiceIsolate::SetServicePort(port); 537 ServiceIsolate::SetServicePort(port);
534 } 538 }
535 539
536 540
537 void ServiceIsolate::VisitObjectPointers(ObjectPointerVisitor* visitor) { 541 void ServiceIsolate::VisitObjectPointers(ObjectPointerVisitor* visitor) {
538 } 542 }
539 543
540 } // namespace dart 544 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/object.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698