libv8-node 21.7.2.0-aarch64-linux-musl → 24.12.0.0-aarch64-linux-musl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (88) hide show
  1. checksums.yaml +4 -4
  2. data/ext/libv8-node/location.rb +3 -5
  3. data/ext/libv8-node/paths.rb +2 -0
  4. data/lib/libv8/node/version.rb +7 -4
  5. data/lib/libv8/node.rb +2 -0
  6. data/lib/libv8-node.rb +2 -0
  7. data/vendor/v8/aarch64-linux-musl/libv8/obj/libv8_monolith.a +0 -0
  8. data/vendor/v8/include/cppgc/allocation.h +11 -13
  9. data/vendor/v8/include/cppgc/default-platform.h +3 -2
  10. data/vendor/v8/include/cppgc/garbage-collected.h +8 -0
  11. data/vendor/v8/include/cppgc/heap-consistency.h +1 -1
  12. data/vendor/v8/include/cppgc/heap-statistics.h +2 -0
  13. data/vendor/v8/include/cppgc/internal/api-constants.h +2 -14
  14. data/vendor/v8/include/cppgc/internal/base-page-handle.h +2 -4
  15. data/vendor/v8/include/cppgc/internal/caged-heap-local-data.h +0 -4
  16. data/vendor/v8/include/cppgc/internal/caged-heap.h +0 -4
  17. data/vendor/v8/include/cppgc/internal/compiler-specific.h +9 -1
  18. data/vendor/v8/include/cppgc/internal/conditional-stack-allocated.h +41 -0
  19. data/vendor/v8/include/cppgc/internal/gc-info.h +12 -10
  20. data/vendor/v8/include/cppgc/internal/logging.h +3 -3
  21. data/vendor/v8/include/cppgc/internal/member-storage.h +69 -20
  22. data/vendor/v8/include/cppgc/internal/name-trait.h +5 -1
  23. data/vendor/v8/include/cppgc/internal/persistent-node.h +8 -3
  24. data/vendor/v8/include/cppgc/internal/pointer-policies.h +48 -11
  25. data/vendor/v8/include/cppgc/macros.h +21 -0
  26. data/vendor/v8/include/cppgc/member.h +70 -36
  27. data/vendor/v8/include/cppgc/name-provider.h +10 -0
  28. data/vendor/v8/include/cppgc/platform.h +11 -0
  29. data/vendor/v8/include/cppgc/type-traits.h +26 -4
  30. data/vendor/v8/include/cppgc/visitor.h +25 -1
  31. data/vendor/v8/include/libplatform/libplatform-export.h +2 -2
  32. data/vendor/v8/include/libplatform/v8-tracing.h +0 -1
  33. data/vendor/v8/include/v8-array-buffer.h +149 -46
  34. data/vendor/v8/include/v8-callbacks.h +100 -43
  35. data/vendor/v8/include/v8-container.h +54 -0
  36. data/vendor/v8/include/v8-context.h +92 -30
  37. data/vendor/v8/include/v8-cppgc.h +5 -56
  38. data/vendor/v8/include/v8-data.h +5 -0
  39. data/vendor/v8/include/v8-date.h +9 -0
  40. data/vendor/v8/include/v8-debug.h +11 -0
  41. data/vendor/v8/include/v8-embedder-heap.h +8 -20
  42. data/vendor/v8/include/v8-embedder-state-scope.h +2 -1
  43. data/vendor/v8/include/v8-exception.h +87 -9
  44. data/vendor/v8/include/v8-external-memory-accounter.h +60 -0
  45. data/vendor/v8/include/v8-fast-api-calls.h +67 -223
  46. data/vendor/v8/include/v8-forward.h +1 -0
  47. data/vendor/v8/include/v8-function-callback.h +296 -75
  48. data/vendor/v8/include/v8-function.h +11 -3
  49. data/vendor/v8/include/v8-handle-base.h +52 -82
  50. data/vendor/v8/include/v8-initialization.h +26 -1
  51. data/vendor/v8/include/v8-inspector.h +26 -27
  52. data/vendor/v8/include/v8-internal.h +960 -230
  53. data/vendor/v8/include/v8-isolate.h +347 -226
  54. data/vendor/v8/include/v8-local-handle.h +307 -55
  55. data/vendor/v8/include/v8-maybe.h +2 -1
  56. data/vendor/v8/include/v8-memory-span.h +284 -4
  57. data/vendor/v8/include/v8-message.h +11 -5
  58. data/vendor/v8/include/v8-metrics.h +15 -0
  59. data/vendor/v8/include/v8-microtask-queue.h +0 -5
  60. data/vendor/v8/include/v8-object.h +314 -41
  61. data/vendor/v8/include/v8-persistent-handle.h +29 -39
  62. data/vendor/v8/include/v8-platform.h +135 -77
  63. data/vendor/v8/include/v8-primitive.h +223 -5
  64. data/vendor/v8/include/v8-profiler.h +51 -2
  65. data/vendor/v8/include/v8-promise.h +2 -2
  66. data/vendor/v8/include/v8-proxy.h +0 -1
  67. data/vendor/v8/include/v8-regexp.h +0 -1
  68. data/vendor/v8/include/v8-sandbox.h +173 -0
  69. data/vendor/v8/include/v8-script.h +125 -27
  70. data/vendor/v8/include/v8-snapshot.h +130 -23
  71. data/vendor/v8/include/v8-source-location.h +6 -1
  72. data/vendor/v8/include/v8-statistics.h +10 -24
  73. data/vendor/v8/include/v8-template.h +320 -193
  74. data/vendor/v8/include/v8-trace-categories.h +23 -0
  75. data/vendor/v8/include/v8-traced-handle.h +99 -76
  76. data/vendor/v8/include/v8-typed-array.h +111 -7
  77. data/vendor/v8/include/v8-unwinder-state.h +2 -3
  78. data/vendor/v8/include/v8-unwinder.h +2 -1
  79. data/vendor/v8/include/v8-util.h +10 -125
  80. data/vendor/v8/include/v8-value-serializer-version.h +3 -3
  81. data/vendor/v8/include/v8-value.h +113 -6
  82. data/vendor/v8/include/v8-version.h +3 -3
  83. data/vendor/v8/include/v8-wasm.h +27 -0
  84. data/vendor/v8/include/v8-weak-callback-info.h +20 -12
  85. data/vendor/v8/include/v8.h +3 -3
  86. data/vendor/v8/include/v8config.h +116 -53
  87. metadata +55 -12
  88. data/vendor/v8/include/cppgc/ephemeron-pair.h +0 -30
@@ -14,7 +14,7 @@
14
14
  #include <string>
15
15
 
16
16
  #include "v8-source-location.h" // NOLINT(build/include_directory)
17
- #include "v8config.h" // NOLINT(build/include_directory)
17
+ #include "v8config.h" // NOLINT(build/include_directory)
18
18
 
19
19
  namespace v8 {
20
20
 
@@ -76,8 +76,13 @@ class TaskRunner {
76
76
  /**
77
77
  * Schedules a task to be invoked by this TaskRunner. The TaskRunner
78
78
  * implementation takes ownership of |task|.
79
+ *
80
+ * Embedders should override PostTaskImpl instead of this.
79
81
  */
80
- virtual void PostTask(std::unique_ptr<Task> task) = 0;
82
+ void PostTask(std::unique_ptr<Task> task,
83
+ const SourceLocation& location = SourceLocation::Current()) {
84
+ PostTaskImpl(std::move(task), location);
85
+ }
81
86
 
82
87
  /**
83
88
  * Schedules a task to be invoked by this TaskRunner. The TaskRunner
@@ -93,16 +98,27 @@ class TaskRunner {
93
98
  * execution is not allowed to nest.
94
99
  *
95
100
  * Requires that |TaskRunner::NonNestableTasksEnabled()| is true.
101
+ *
102
+ * Embedders should override PostNonNestableTaskImpl instead of this.
96
103
  */
97
- virtual void PostNonNestableTask(std::unique_ptr<Task> task) {}
104
+ void PostNonNestableTask(
105
+ std::unique_ptr<Task> task,
106
+ const SourceLocation& location = SourceLocation::Current()) {
107
+ PostNonNestableTaskImpl(std::move(task), location);
108
+ }
98
109
 
99
110
  /**
100
111
  * Schedules a task to be invoked by this TaskRunner. The task is scheduled
101
112
  * after the given number of seconds |delay_in_seconds|. The TaskRunner
102
113
  * implementation takes ownership of |task|.
114
+ *
115
+ * Embedders should override PostDelayedTaskImpl instead of this.
103
116
  */
104
- virtual void PostDelayedTask(std::unique_ptr<Task> task,
105
- double delay_in_seconds) = 0;
117
+ void PostDelayedTask(
118
+ std::unique_ptr<Task> task, double delay_in_seconds,
119
+ const SourceLocation& location = SourceLocation::Current()) {
120
+ PostDelayedTaskImpl(std::move(task), delay_in_seconds, location);
121
+ }
106
122
 
107
123
  /**
108
124
  * Schedules a task to be invoked by this TaskRunner. The task is scheduled
@@ -119,9 +135,14 @@ class TaskRunner {
119
135
  * execution is not allowed to nest.
120
136
  *
121
137
  * Requires that |TaskRunner::NonNestableDelayedTasksEnabled()| is true.
138
+ *
139
+ * Embedders should override PostNonNestableDelayedTaskImpl instead of this.
122
140
  */
123
- virtual void PostNonNestableDelayedTask(std::unique_ptr<Task> task,
124
- double delay_in_seconds) {}
141
+ void PostNonNestableDelayedTask(
142
+ std::unique_ptr<Task> task, double delay_in_seconds,
143
+ const SourceLocation& location = SourceLocation::Current()) {
144
+ PostNonNestableDelayedTaskImpl(std::move(task), delay_in_seconds, location);
145
+ }
125
146
 
126
147
  /**
127
148
  * Schedules an idle task to be invoked by this TaskRunner. The task is
@@ -130,8 +151,14 @@ class TaskRunner {
130
151
  * relative to other task types and may be starved for an arbitrarily long
131
152
  * time if no idle time is available. The TaskRunner implementation takes
132
153
  * ownership of |task|.
154
+ *
155
+ * Embedders should override PostIdleTaskImpl instead of this.
133
156
  */
134
- virtual void PostIdleTask(std::unique_ptr<IdleTask> task) = 0;
157
+ void PostIdleTask(
158
+ std::unique_ptr<IdleTask> task,
159
+ const SourceLocation& location = SourceLocation::Current()) {
160
+ PostIdleTaskImpl(std::move(task), location);
161
+ }
135
162
 
136
163
  /**
137
164
  * Returns true if idle tasks are enabled for this TaskRunner.
@@ -153,6 +180,23 @@ class TaskRunner {
153
180
 
154
181
  TaskRunner(const TaskRunner&) = delete;
155
182
  TaskRunner& operator=(const TaskRunner&) = delete;
183
+
184
+ protected:
185
+ /**
186
+ * Implementation of above methods with an additional `location` argument.
187
+ */
188
+ virtual void PostTaskImpl(std::unique_ptr<Task> task,
189
+ const SourceLocation& location) {}
190
+ virtual void PostNonNestableTaskImpl(std::unique_ptr<Task> task,
191
+ const SourceLocation& location) {}
192
+ virtual void PostDelayedTaskImpl(std::unique_ptr<Task> task,
193
+ double delay_in_seconds,
194
+ const SourceLocation& location) {}
195
+ virtual void PostNonNestableDelayedTaskImpl(std::unique_ptr<Task> task,
196
+ double delay_in_seconds,
197
+ const SourceLocation& location) {}
198
+ virtual void PostIdleTaskImpl(std::unique_ptr<IdleTask> task,
199
+ const SourceLocation& location) {}
156
200
  };
157
201
 
158
202
  /**
@@ -350,7 +394,7 @@ class TracingController {
350
394
 
351
395
  /**
352
396
  * Adds a trace event to the platform tracing system. These function calls are
353
- * usually the result of a TRACE_* macro from trace_event_common.h when
397
+ * usually the result of a TRACE_* macro from trace-event-no-perfetto.h when
354
398
  * tracing and the category of the particular trace are enabled. It is not
355
399
  * advisable to call these functions on their own; they are really only meant
356
400
  * to be used by the trace macros. The returned handle can be used by
@@ -508,6 +552,19 @@ class PageAllocator {
508
552
  */
509
553
  virtual bool DecommitPages(void* address, size_t size) = 0;
510
554
 
555
+ /**
556
+ * Block any modifications to the given mapping such as changing permissions
557
+ * or unmapping the pages on supported platforms.
558
+ * The address space reservation will exist until the process ends, but it's
559
+ * possible to release the memory using DiscardSystemPages. Note that this
560
+ * might require write permissions to the page as e.g. on Linux, mseal will
561
+ * block discarding sealed anonymous memory.
562
+ */
563
+ virtual bool SealPages(void* address, size_t length) {
564
+ // TODO(360048056): make it pure once it's implemented on Chromium side.
565
+ return false;
566
+ }
567
+
511
568
  /**
512
569
  * INTERNAL ONLY: This interface has not been stabilised and may change
513
570
  * without notice from one release to another without being deprecated first.
@@ -736,6 +793,15 @@ class VirtualAddressSpace {
736
793
  */
737
794
  PagePermissions max_page_permissions() const { return max_page_permissions_; }
738
795
 
796
+ /**
797
+ * Whether the |address| is inside the address space managed by this instance.
798
+ *
799
+ * \returns true if it is inside the address space, false if not.
800
+ */
801
+ bool Contains(Address address) const {
802
+ return (address >= base()) && (address < base() + size());
803
+ }
804
+
739
805
  /**
740
806
  * Sets the random seed so that GetRandomPageAddress() will generate
741
807
  * repeatable sequences of random addresses.
@@ -973,18 +1039,6 @@ class VirtualAddressSpace {
973
1039
  const PagePermissions max_page_permissions_;
974
1040
  };
975
1041
 
976
- /**
977
- * V8 Allocator used for allocating zone backings.
978
- */
979
- class ZoneBackingAllocator {
980
- public:
981
- using MallocFn = void* (*)(size_t);
982
- using FreeFn = void (*)(void*);
983
-
984
- virtual MallocFn GetMallocFn() const { return ::malloc; }
985
- virtual FreeFn GetFreeFn() const { return ::free; }
986
- };
987
-
988
1042
  /**
989
1043
  * Observer used by V8 to notify the embedder about entering/leaving sections
990
1044
  * with high throughput of malloc/free operations.
@@ -1009,7 +1063,7 @@ class Platform {
1009
1063
  * Allows the embedder to manage memory page allocations.
1010
1064
  * Returning nullptr will cause V8 to use the default page allocator.
1011
1065
  */
1012
- virtual PageAllocator* GetPageAllocator() = 0;
1066
+ virtual PageAllocator* GetPageAllocator() { return nullptr; }
1013
1067
 
1014
1068
  /**
1015
1069
  * Allows the embedder to provide an allocator that uses per-thread memory
@@ -1021,14 +1075,6 @@ class Platform {
1021
1075
  return nullptr;
1022
1076
  }
1023
1077
 
1024
- /**
1025
- * Allows the embedder to specify a custom allocator used for zones.
1026
- */
1027
- virtual ZoneBackingAllocator* GetZoneBackingAllocator() {
1028
- static ZoneBackingAllocator default_allocator;
1029
- return &default_allocator;
1030
- }
1031
-
1032
1078
  /**
1033
1079
  * Enables the embedder to respond in cases where V8 can't allocate large
1034
1080
  * blocks of memory. V8 retries the failed allocation once after calling this
@@ -1052,11 +1098,8 @@ class Platform {
1052
1098
  * Returns a TaskRunner which can be used to post a task on the foreground.
1053
1099
  * The TaskRunner's NonNestableTasksEnabled() must be true. This function
1054
1100
  * should only be called from a foreground thread.
1055
- * TODO(chromium:1448758): Deprecate once |GetForegroundTaskRunner(Isolate*,
1056
- * TaskPriority)| is ready.
1057
1101
  */
1058
- virtual std::shared_ptr<v8::TaskRunner> GetForegroundTaskRunner(
1059
- Isolate* isolate) {
1102
+ std::shared_ptr<v8::TaskRunner> GetForegroundTaskRunner(Isolate* isolate) {
1060
1103
  return GetForegroundTaskRunner(isolate, TaskPriority::kUserBlocking);
1061
1104
  }
1062
1105
 
@@ -1064,23 +1107,21 @@ class Platform {
1064
1107
  * Returns a TaskRunner with a specific |priority| which can be used to post a
1065
1108
  * task on the foreground thread. The TaskRunner's NonNestableTasksEnabled()
1066
1109
  * must be true. This function should only be called from a foreground thread.
1067
- * TODO(chromium:1448758): Make pure virtual once embedders implement it.
1068
1110
  */
1069
1111
  virtual std::shared_ptr<v8::TaskRunner> GetForegroundTaskRunner(
1070
- Isolate* isolate, TaskPriority priority) {
1071
- return nullptr;
1072
- }
1112
+ Isolate* isolate, TaskPriority priority) = 0;
1073
1113
 
1074
1114
  /**
1075
1115
  * Schedules a task to be invoked on a worker thread.
1076
1116
  * Embedders should override PostTaskOnWorkerThreadImpl() instead of
1077
1117
  * CallOnWorkerThread().
1078
- * TODO(chromium:1424158): Make non-virtual once embedders are migrated to
1079
- * PostTaskOnWorkerThreadImpl().
1080
1118
  */
1081
- virtual void CallOnWorkerThread(std::unique_ptr<Task> task) {
1119
+ V8_DEPRECATE_SOON("Use PostTaskOnWorkerThread instead.")
1120
+ void CallOnWorkerThread(
1121
+ std::unique_ptr<Task> task,
1122
+ const SourceLocation& location = SourceLocation::Current()) {
1082
1123
  PostTaskOnWorkerThreadImpl(TaskPriority::kUserVisible, std::move(task),
1083
- SourceLocation::Current());
1124
+ location);
1084
1125
  }
1085
1126
 
1086
1127
  /**
@@ -1088,28 +1129,30 @@ class Platform {
1088
1129
  * high-priority on a worker thread.
1089
1130
  * Embedders should override PostTaskOnWorkerThreadImpl() instead of
1090
1131
  * CallBlockingTaskOnWorkerThread().
1091
- * TODO(chromium:1424158): Make non-virtual once embedders are migrated to
1092
- * PostTaskOnWorkerThreadImpl().
1093
1132
  */
1094
- virtual void CallBlockingTaskOnWorkerThread(std::unique_ptr<Task> task) {
1133
+ V8_DEPRECATE_SOON("Use PostTaskOnWorkerThread instead.")
1134
+ void CallBlockingTaskOnWorkerThread(
1135
+ std::unique_ptr<Task> task,
1136
+ const SourceLocation& location = SourceLocation::Current()) {
1095
1137
  // Embedders may optionally override this to process these tasks in a high
1096
1138
  // priority pool.
1097
1139
  PostTaskOnWorkerThreadImpl(TaskPriority::kUserBlocking, std::move(task),
1098
- SourceLocation::Current());
1140
+ location);
1099
1141
  }
1100
1142
 
1101
1143
  /**
1102
1144
  * Schedules a task to be invoked with low-priority on a worker thread.
1103
1145
  * Embedders should override PostTaskOnWorkerThreadImpl() instead of
1104
1146
  * CallLowPriorityTaskOnWorkerThread().
1105
- * TODO(chromium:1424158): Make non-virtual once embedders are migrated to
1106
- * PostTaskOnWorkerThreadImpl().
1107
1147
  */
1108
- virtual void CallLowPriorityTaskOnWorkerThread(std::unique_ptr<Task> task) {
1148
+ V8_DEPRECATE_SOON("Use PostTaskOnWorkerThread instead.")
1149
+ void CallLowPriorityTaskOnWorkerThread(
1150
+ std::unique_ptr<Task> task,
1151
+ const SourceLocation& location = SourceLocation::Current()) {
1109
1152
  // Embedders may optionally override this to process these tasks in a low
1110
1153
  // priority pool.
1111
1154
  PostTaskOnWorkerThreadImpl(TaskPriority::kBestEffort, std::move(task),
1112
- SourceLocation::Current());
1155
+ location);
1113
1156
  }
1114
1157
 
1115
1158
  /**
@@ -1117,14 +1160,39 @@ class Platform {
1117
1160
  * expires.
1118
1161
  * Embedders should override PostDelayedTaskOnWorkerThreadImpl() instead of
1119
1162
  * CallDelayedOnWorkerThread().
1120
- * TODO(chromium:1424158): Make non-virtual once embedders are migrated to
1121
- * PostDelayedTaskOnWorkerThreadImpl().
1122
1163
  */
1123
- virtual void CallDelayedOnWorkerThread(std::unique_ptr<Task> task,
1124
- double delay_in_seconds) {
1164
+ V8_DEPRECATE_SOON("Use PostDelayedTaskOnWorkerThread instead.")
1165
+ void CallDelayedOnWorkerThread(
1166
+ std::unique_ptr<Task> task, double delay_in_seconds,
1167
+ const SourceLocation& location = SourceLocation::Current()) {
1125
1168
  PostDelayedTaskOnWorkerThreadImpl(TaskPriority::kUserVisible,
1126
1169
  std::move(task), delay_in_seconds,
1127
- SourceLocation::Current());
1170
+ location);
1171
+ }
1172
+
1173
+ /**
1174
+ * Schedules a task to be invoked on a worker thread.
1175
+ * Embedders should override PostTaskOnWorkerThreadImpl() instead of
1176
+ * PostTaskOnWorkerThread().
1177
+ */
1178
+ void PostTaskOnWorkerThread(
1179
+ TaskPriority priority, std::unique_ptr<Task> task,
1180
+ const SourceLocation& location = SourceLocation::Current()) {
1181
+ PostTaskOnWorkerThreadImpl(priority, std::move(task), location);
1182
+ }
1183
+
1184
+ /**
1185
+ * Schedules a task to be invoked on a worker thread after |delay_in_seconds|
1186
+ * expires.
1187
+ * Embedders should override PostDelayedTaskOnWorkerThreadImpl() instead of
1188
+ * PostDelayedTaskOnWorkerThread().
1189
+ */
1190
+ void PostDelayedTaskOnWorkerThread(
1191
+ TaskPriority priority, std::unique_ptr<Task> task,
1192
+ double delay_in_seconds,
1193
+ const SourceLocation& location = SourceLocation::Current()) {
1194
+ PostDelayedTaskOnWorkerThreadImpl(priority, std::move(task),
1195
+ delay_in_seconds, location);
1128
1196
  }
1129
1197
 
1130
1198
  /**
@@ -1176,12 +1244,11 @@ class Platform {
1176
1244
  * JobTask::GetMaxConcurrency may be invoked synchronously from JobHandle
1177
1245
  * (B=>JobHandle::foo=>B deadlock).
1178
1246
  * Embedders should override CreateJobImpl() instead of PostJob().
1179
- * TODO(chromium:1424158): Make non-virtual once embedders are migrated to
1180
- * CreateJobImpl().
1181
1247
  */
1182
- virtual std::unique_ptr<JobHandle> PostJob(
1183
- TaskPriority priority, std::unique_ptr<JobTask> job_task) {
1184
- auto handle = CreateJob(priority, std::move(job_task));
1248
+ std::unique_ptr<JobHandle> PostJob(
1249
+ TaskPriority priority, std::unique_ptr<JobTask> job_task,
1250
+ const SourceLocation& location = SourceLocation::Current()) {
1251
+ auto handle = CreateJob(priority, std::move(job_task), location);
1185
1252
  handle->NotifyConcurrencyIncrease();
1186
1253
  return handle;
1187
1254
  }
@@ -1200,13 +1267,11 @@ class Platform {
1200
1267
  * }
1201
1268
  *
1202
1269
  * Embedders should override CreateJobImpl() instead of CreateJob().
1203
- * TODO(chromium:1424158): Make non-virtual once embedders are migrated to
1204
- * CreateJobImpl().
1205
1270
  */
1206
- virtual std::unique_ptr<JobHandle> CreateJob(
1207
- TaskPriority priority, std::unique_ptr<JobTask> job_task) {
1208
- return CreateJobImpl(priority, std::move(job_task),
1209
- SourceLocation::Current());
1271
+ std::unique_ptr<JobHandle> CreateJob(
1272
+ TaskPriority priority, std::unique_ptr<JobTask> job_task,
1273
+ const SourceLocation& location = SourceLocation::Current()) {
1274
+ return CreateJobImpl(priority, std::move(job_task), location);
1210
1275
  }
1211
1276
 
1212
1277
  /**
@@ -1232,7 +1297,7 @@ class Platform {
1232
1297
  * required.
1233
1298
  */
1234
1299
  virtual int64_t CurrentClockTimeMilliseconds() {
1235
- return floor(CurrentClockTimeMillis());
1300
+ return static_cast<int64_t>(floor(CurrentClockTimeMillis()));
1236
1301
  }
1237
1302
 
1238
1303
  /**
@@ -1288,32 +1353,25 @@ class Platform {
1288
1353
 
1289
1354
  /**
1290
1355
  * Creates and returns a JobHandle associated with a Job.
1291
- * TODO(chromium:1424158): Make pure virtual once embedders implement it.
1292
1356
  */
1293
1357
  virtual std::unique_ptr<JobHandle> CreateJobImpl(
1294
1358
  TaskPriority priority, std::unique_ptr<JobTask> job_task,
1295
- const SourceLocation& location) {
1296
- return nullptr;
1297
- }
1359
+ const SourceLocation& location) = 0;
1298
1360
 
1299
1361
  /**
1300
1362
  * Schedules a task with |priority| to be invoked on a worker thread.
1301
- * TODO(chromium:1424158): Make pure virtual once embedders implement it.
1302
1363
  */
1303
1364
  virtual void PostTaskOnWorkerThreadImpl(TaskPriority priority,
1304
1365
  std::unique_ptr<Task> task,
1305
- const SourceLocation& location) {
1306
- CallOnWorkerThread(std::move(task));
1307
- }
1366
+ const SourceLocation& location) = 0;
1308
1367
 
1309
1368
  /**
1310
1369
  * Schedules a task with |priority| to be invoked on a worker thread after
1311
1370
  * |delay_in_seconds| expires.
1312
- * TODO(chromium:1424158): Make pure virtual once embedders implement it.
1313
1371
  */
1314
1372
  virtual void PostDelayedTaskOnWorkerThreadImpl(
1315
1373
  TaskPriority priority, std::unique_ptr<Task> task,
1316
- double delay_in_seconds, const SourceLocation& location) {}
1374
+ double delay_in_seconds, const SourceLocation& location) = 0;
1317
1375
  };
1318
1376
 
1319
1377
  } // namespace v8