Update JS Self-Profiler IDL to latest spec

As per the latest spec changes, expose profiler creation synchronously
on the constructor rather than through performance.profile.

Bug: 956688
Change-Id: I3f8637d30c81afb21baa0f2a01565b4902bfb76e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2993062
Commit-Queue: Andrew Comminos <acomminos@fb.com>
Reviewed-by: Nicolás Peña Moreno <npm@chromium.org>
Cr-Commit-Position: refs/heads/master@{#897625}
diff --git a/interfaces/js-self-profiling.idl b/interfaces/js-self-profiling.idl
index b5cb290..5285767 100644
--- a/interfaces/js-self-profiling.idl
+++ b/interfaces/js-self-profiling.idl
@@ -8,6 +8,7 @@
   readonly attribute DOMHighResTimeStamp sampleInterval;
   readonly attribute boolean stopped;
 
+  constructor(ProfilerInitOptions options);
   Promise<ProfilerTrace> stop();
 };
 
@@ -41,8 +42,3 @@
   required DOMHighResTimeStamp sampleInterval;
   required unsigned long maxBufferSize;
 };
-
-[CrossOriginIsolated, Exposed=(Window,Worker)]
-partial interface Performance {
-  Promise<Profiler> profile(ProfilerInitOptions options);
-};
diff --git a/js-self-profiling/idlharness.https.html b/js-self-profiling/idlharness.https.html
index 0b6aa6c..716667e 100644
--- a/js-self-profiling/idlharness.https.html
+++ b/js-self-profiling/idlharness.https.html
@@ -13,11 +13,10 @@
           ['hr-time', 'dom'],
           async idl_array => {
                 idl_array.add_objects({
-                      Performance: ['performance'],
                       Profiler: ['profiler'],
                     });
 
-                self.profiler = await performance.profile({
+                self.profiler = new Profiler({
                       sampleInterval: 1,
                     });
               }