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

Side by Side Diff: runtime/bin/main.cc

Issue 10990028: Add code for CPU feature detection and use it to detect SSE3 and SSE 4.1. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: addressed comments Created 8 years, 2 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 | Annotate | Revision Log
« no previous file with comments | « runtime/bin/gen_snapshot.cc ('k') | runtime/vm/assembler_ia32.h » ('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 (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 <stdlib.h> 5 #include <stdlib.h>
6 #include <string.h> 6 #include <string.h>
7 #include <stdio.h> 7 #include <stdio.h>
8 8
9 #include "include/dart_api.h" 9 #include "include/dart_api.h"
10 #include "include/dart_debugger_api.h" 10 #include "include/dart_debugger_api.h"
(...skipping 637 matching lines...) Expand 10 before | Expand all | Expand 10 after
648 } 648 }
649 649
650 if (has_help_option) { 650 if (has_help_option) {
651 PrintUsage(); 651 PrintUsage();
652 return 0; 652 return 0;
653 } 653 }
654 654
655 Dart_SetVMFlags(vm_options.count(), vm_options.arguments()); 655 Dart_SetVMFlags(vm_options.count(), vm_options.arguments());
656 656
657 // Initialize the Dart VM. 657 // Initialize the Dart VM.
658 Dart_Initialize(CreateIsolateAndSetup, 658 if (!Dart_Initialize(CreateIsolateAndSetup,
659 NULL, 659 NULL,
660 ShutdownIsolate); 660 ShutdownIsolate)) {
661 return ErrorExit("VM initialization failed\n");
662 }
661 663
662 DartUtils::SetOriginalWorkingDirectory(); 664 DartUtils::SetOriginalWorkingDirectory();
663 665
664 // Call CreateIsolateAndSetup which creates an isolate and loads up 666 // Call CreateIsolateAndSetup which creates an isolate and loads up
665 // the specified application script. 667 // the specified application script.
666 char* error = NULL; 668 char* error = NULL;
667 char* isolate_name = BuildIsolateName(script_name, "main"); 669 char* isolate_name = BuildIsolateName(script_name, "main");
668 if (!CreateIsolateAndSetupHelper(script_name, 670 if (!CreateIsolateAndSetupHelper(script_name,
669 "main", 671 "main",
670 true, // Canonicalize the script name. 672 true, // Canonicalize the script name.
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
732 Dart_ExitScope(); 734 Dart_ExitScope();
733 // Dump symbol information for the profiler. 735 // Dump symbol information for the profiler.
734 DumpPprofSymbolInfo(); 736 DumpPprofSymbolInfo();
735 // Shutdown the isolate. 737 // Shutdown the isolate.
736 Dart_ShutdownIsolate(); 738 Dart_ShutdownIsolate();
737 // Terminate process exit-code handler. 739 // Terminate process exit-code handler.
738 Process::TerminateExitCodeHandler(); 740 Process::TerminateExitCodeHandler();
739 741
740 return 0; 742 return 0;
741 } 743 }
OLDNEW
« no previous file with comments | « runtime/bin/gen_snapshot.cc ('k') | runtime/vm/assembler_ia32.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698