2016-07-17 08:00:03 +00:00
|
|
|
$NetBSD$
|
|
|
|
|
2020-07-27 03:07:44 +00:00
|
|
|
--- content/renderer/render_thread_impl.cc.orig 2020-07-08 21:41:48.000000000 +0000
|
2016-07-17 08:00:03 +00:00
|
|
|
+++ content/renderer/render_thread_impl.cc
|
2020-07-27 03:07:44 +00:00
|
|
|
@@ -177,6 +177,12 @@
|
2017-02-17 22:27:08 +00:00
|
|
|
|
|
|
|
#if defined(OS_MACOSX)
|
|
|
|
#include <malloc/malloc.h>
|
2020-07-27 03:07:44 +00:00
|
|
|
+#elif defined(OS_BSD)
|
|
|
|
+#include <stdlib.h>
|
|
|
|
+#include <stddef.h>
|
|
|
|
+#include <stdint.h>
|
|
|
|
+#include <sys/param.h>
|
|
|
|
+#include <sys/sysctl.h>
|
2017-02-17 22:27:08 +00:00
|
|
|
#else
|
|
|
|
#include <malloc.h>
|
|
|
|
#endif
|
2020-07-27 03:07:44 +00:00
|
|
|
@@ -752,7 +758,7 @@ void RenderThreadImpl::Init() {
|
|
|
|
DCHECK(parsed_num_raster_threads) << string_value;
|
|
|
|
DCHECK_GT(num_raster_threads, 0);
|
2017-02-17 22:27:08 +00:00
|
|
|
|
2020-07-27 03:07:44 +00:00
|
|
|
-#if defined(OS_LINUX)
|
|
|
|
+#if defined(OS_LINUX) || defined(OS_BSD)
|
|
|
|
categorized_worker_pool_->SetBackgroundingCallback(
|
|
|
|
main_thread_scheduler_->DefaultTaskRunner(),
|
|
|
|
base::BindOnce(
|
|
|
|
@@ -775,7 +781,7 @@ void RenderThreadImpl::Init() {
|
|
|
|
base::DiscardableMemoryAllocator::SetInstance(
|
|
|
|
discardable_memory_allocator_.get());
|
|
|
|
|
|
|
|
-#if defined(OS_LINUX)
|
|
|
|
+#if defined(OS_LINUX) || defined(OS_BSD)
|
|
|
|
if (base::FeatureList::IsEnabled(
|
|
|
|
blink::features::kBlinkCompositorUseDisplayThreadPriority)) {
|
|
|
|
render_message_filter()->SetThreadPriority(
|