Reviewers: Yang,

Description:
Make vtune-jit stop using deprecated APIs

BUG=v8:4134
[email protected]
LOG=n

Please review this at https://codereview.chromium.org/1244433003/

Base URL: https://chromium.googlesource.com/v8/v8.git@master

Affected files (+7, -2 lines):
  M src/third_party/vtune/v8vtune.gyp
  M src/third_party/vtune/vtune-jit.cc


Index: src/third_party/vtune/v8vtune.gyp
diff --git a/src/third_party/vtune/v8vtune.gyp b/src/third_party/vtune/v8vtune.gyp index 6adf3656892f7db523bed826a26d26dab2d552e5..92df29a82b99d88bb9b7260f28b37b81089e3529 100644
--- a/src/third_party/vtune/v8vtune.gyp
+++ b/src/third_party/vtune/v8vtune.gyp
@@ -37,6 +37,10 @@
       'dependencies': [
         '../../../tools/gyp/v8.gyp:v8',
       ],
+      'defines': [
+        # TODO(jochen): Remove again after this is globally turned on.
+        'V8_IMMINENT_DEPRECATION_WARNINGS',
+      ],
       'sources': [
         'ittnotify_config.h',
         'ittnotify_types.h',
Index: src/third_party/vtune/vtune-jit.cc
diff --git a/src/third_party/vtune/vtune-jit.cc b/src/third_party/vtune/vtune-jit.cc index b621cbcb8f4212cee862b1f5f9db002186e3ef9b..30f6196001930fdf07d6e390b22243572fb0e517 100644
--- a/src/third_party/vtune/vtune-jit.cc
+++ b/src/third_party/vtune/vtune-jit.cc
@@ -192,12 +192,13 @@ void VTUNEJITInterface::event_handler(const v8::JitCodeEvent* event) {
         jmethod.method_size = static_cast<unsigned int>(event->code_len);
         jmethod.method_name = temp_method_name;

-        Handle<UnboundScript> script = event->script;
+        Local<UnboundScript> script = event->script;

         if (*script != NULL) {
// Get the source file name and set it to jmethod.source_file_name
           if ((*script->GetScriptName())->IsString()) {
- Handle<String> script_name = script->GetScriptName()->ToString();
+            Local<String> script_name =
+                Local<String>::Cast(script->GetScriptName());
             temp_file_name = new char[script_name->Utf8Length() + 1];
             script_name->WriteUtf8(temp_file_name);
             jmethod.source_file_name = temp_file_name;


--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to