OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 27 matching lines...) Expand all Loading... |
38 #include <errno.h> | 38 #include <errno.h> |
39 #include <stdlib.h> | 39 #include <stdlib.h> |
40 #include <string.h> | 40 #include <string.h> |
41 #include <sys/stat.h> | 41 #include <sys/stat.h> |
42 | 42 |
43 #ifdef V8_SHARED | 43 #ifdef V8_SHARED |
44 #include <assert.h> | 44 #include <assert.h> |
45 #include "../include/v8-testing.h" | 45 #include "../include/v8-testing.h" |
46 #endif // V8_SHARED | 46 #endif // V8_SHARED |
47 | 47 |
| 48 #ifdef ENABLE_VTUNE_JIT_INTERFACE |
| 49 #include "third_party/vtune/v8-vtune.h" |
| 50 #endif |
| 51 |
48 #include "d8.h" | 52 #include "d8.h" |
49 | 53 |
50 #ifndef V8_SHARED | 54 #ifndef V8_SHARED |
51 #include "api.h" | 55 #include "api.h" |
52 #include "checks.h" | 56 #include "checks.h" |
53 #include "d8-debug.h" | 57 #include "d8-debug.h" |
54 #include "debug.h" | 58 #include "debug.h" |
55 #include "natives.h" | 59 #include "natives.h" |
56 #include "platform.h" | 60 #include "platform.h" |
57 #include "v8.h" | 61 #include "v8.h" |
(...skipping 1837 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1895 } | 1899 } |
1896 | 1900 |
1897 | 1901 |
1898 int Shell::Main(int argc, char* argv[]) { | 1902 int Shell::Main(int argc, char* argv[]) { |
1899 if (!SetOptions(argc, argv)) return 1; | 1903 if (!SetOptions(argc, argv)) return 1; |
1900 int result = 0; | 1904 int result = 0; |
1901 Isolate* isolate = Isolate::GetCurrent(); | 1905 Isolate* isolate = Isolate::GetCurrent(); |
1902 DumbLineEditor dumb_line_editor(isolate); | 1906 DumbLineEditor dumb_line_editor(isolate); |
1903 { | 1907 { |
1904 Initialize(isolate); | 1908 Initialize(isolate); |
| 1909 #ifdef ENABLE_VTUNE_JIT_INTERFACE |
| 1910 vTune::InitilizeVtuneForV8(); |
| 1911 #endif |
1905 Symbols symbols(isolate); | 1912 Symbols symbols(isolate); |
1906 InitializeDebugger(isolate); | 1913 InitializeDebugger(isolate); |
1907 | 1914 |
1908 if (options.stress_opt || options.stress_deopt) { | 1915 if (options.stress_opt || options.stress_deopt) { |
1909 Testing::SetStressRunType(options.stress_opt | 1916 Testing::SetStressRunType(options.stress_opt |
1910 ? Testing::kStressTypeOpt | 1917 ? Testing::kStressTypeOpt |
1911 : Testing::kStressTypeDeopt); | 1918 : Testing::kStressTypeDeopt); |
1912 int stress_runs = Testing::GetStressRuns(); | 1919 int stress_runs = Testing::GetStressRuns(); |
1913 for (int i = 0; i < stress_runs && result == 0; i++) { | 1920 for (int i = 0; i < stress_runs && result == 0; i++) { |
1914 printf("============ Stress %d/%d ============\n", i + 1, stress_runs); | 1921 printf("============ Stress %d/%d ============\n", i + 1, stress_runs); |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1962 } | 1969 } |
1963 | 1970 |
1964 } // namespace v8 | 1971 } // namespace v8 |
1965 | 1972 |
1966 | 1973 |
1967 #ifndef GOOGLE3 | 1974 #ifndef GOOGLE3 |
1968 int main(int argc, char* argv[]) { | 1975 int main(int argc, char* argv[]) { |
1969 return v8::Shell::Main(argc, argv); | 1976 return v8::Shell::Main(argc, argv); |
1970 } | 1977 } |
1971 #endif | 1978 #endif |
OLD | NEW |