1 Star 0 Fork 230

wangyulie/resourceschedule_ffrt_for_others_sync

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
BUILD.gn 4.12 KB
一键复制 编辑 原始数据 按行查看 历史
wangyulie95 提交于 2023-07-28 15:45 . asan patch
# Copyright (c) 2023 Huawei Device Co., Ltd.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import("//build/ohos.gni")
import("//foundation/resourceschedule/ffrt/ffrt_stackless_coroutine.gni")
defines = []
if (use_stackless_coroutine) {
defines += [ "USE_STACKLESS_COROUTINE" ]
}
config("ffrt_config") {
visibility = [ ":*" ]
include_dirs = [
"src",
"interfaces/kits",
"interfaces/inner_api",
"src/dfx/log",
"//third_party/jsoncpp/include",
"//foundation/resourceschedule/frame_aware_sched/common/include/",
"//third_party/libunwind/include",
"//base/hiviewdfx/hitrace/interfaces/native/innerkits/include/hitrace_meter/",
]
ffrt_defaults_cflags = [
"-g",
"-D_FORTIFY_SOURCE=2",
"-O2",
"-fPIC",
"-Wno-unused-variable",
"-Wno-unused-function",
"-Wno-unused-value",
"-Wno-unused-private-field",
"-Wno-shadow",
"-Wno-float-equal",
"-Wno-unused-parameter",
"-DOHOS_STANDARD_SYSTEM",
"-DTASKSTAT_LOG_ENABLE=0",
"-DIDLE_WORKER_DESTRUCT",
]
cflags = ffrt_defaults_cflags
cflags_cc = ffrt_defaults_cflags
cflags_cc += [ "-std=c++17" ]
ffrt_debug_defines = [
"FFRT_LOG_LEVEL=3",
"FFRT_BBOX_ENABLE",
"FFRT_OH_EVENT_RECORD",
"FFRT_CO_BACKTRACE_OH_ENABLE",
"FFRT_OH_TRACE_ENABLE",
"FFRT_OH_TASK_STAT_ENABLE",
"FFRT_TRACE_LEVEL=1",
]
#ffrt_release_defines = [
# "FFRT_LOG_LEVEL=0",
# "FFRT_RELEASE",
#]
defines += ffrt_debug_defines
if (is_asan) {
defines += [ "ASAN_MODE" ]
}
#defines += ffrt_release_defines
}
ohos_shared_library("libffrt") {
public_configs = [ ":ffrt_config" ]
sources = [
"src/core/entity.cpp",
"src/core/task.cpp",
"src/core/task_ctx.cpp",
"src/core/version_ctx.cpp",
"src/dfx/bbox/bbox.cpp",
"src/dfx/log/ffrt_log.cpp",
"src/dfx/log/hmos/log_base.cpp",
"src/dfx/trace/ffrt_trace.cpp",
"src/dfx/watchdog/watchdog.cpp",
"src/eu/co2_context.c",
"src/eu/co_routine.cpp",
"src/eu/cpu_monitor.cpp",
"src/eu/cpu_worker.cpp",
"src/eu/cpuworker_manager.cpp",
"src/eu/execute_unit.cpp",
"src/eu/osattr_manager.cpp",
"src/eu/qos_config.cpp",
"src/eu/qos_convert.cpp",
"src/eu/qos_interface.cpp",
"src/eu/rtg_ioctl.cpp",
"src/eu/rtg_perf_ctrl.c",
"src/eu/worker_manager.cpp",
"src/eu/worker_thread.cpp",
"src/queue/queue_monitor.cpp",
"src/queue/serial_handler.cpp",
"src/queue/serial_looper.cpp",
"src/queue/serial_queue.cpp",
"src/queue/serial_queue_api.cpp",
"src/queue/serial_task.cpp",
"src/sched/deadline.cpp",
"src/sched/execute_ctx.cpp",
"src/sched/frame_interval.cpp",
"src/sched/interval.cpp",
"src/sched/load_tracking.cpp",
"src/sched/multi_workgroup.cpp",
"src/sched/sched_deadline.cpp",
"src/sched/task_manager.cpp",
"src/sched/task_state.cpp",
"src/sync/condition_variable.cpp",
"src/sync/delayed_worker.cpp",
"src/sync/io_poller.cpp",
"src/sync/mutex.cpp",
"src/sync/mutex_perf.cpp",
"src/sync/perf_counter.cpp",
"src/sync/sleep.cpp",
"src/sync/sync.cpp",
"src/sync/thread.cpp",
"src/sync/wait_queue.cpp",
"src/util/graph_check.cpp",
"src/util/task_deleter.cpp",
]
external_deps = [
"faultloggerd:libbacktrace_local",
"frame_aware_sched:rtg_interface",
"hilog:libhilog",
"hisysevent:libhisysevent",
"hitrace:hitrace_meter",
"ipc:ipc_core",
]
deps = [
"//third_party/bounds_checking_function:libsec_shared",
"//third_party/libunwind:libunwind",
]
output_extension = "so"
part_name = "ffrt"
install_images = [
"system",
"updater",
]
relative_install_dir = "chipset-sdk"
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/wangyulie/resourceschedule_ffrt_2.git
git@gitee.com:wangyulie/resourceschedule_ffrt_2.git
wangyulie
resourceschedule_ffrt_2
resourceschedule_ffrt_for_others_sync
master

搜索帮助