blob: 973f857a861cdb8d402b153211ff86ebb0f82983 [file] [log] [blame]
Colin Crossf6298102017-04-19 15:25:25 -07001cc_defaults {
2 name: "hwui_defaults",
3 defaults: [
4 "hwui_static_deps",
Pirama Arumuga Nainar0dfd4be2017-11-16 22:40:00 -08005 "skia_deps",
Colin Crossf6298102017-04-19 15:25:25 -07006 //"hwui_bugreport_font_cache_usage",
7 //"hwui_compile_for_perf",
Pirama Arumuga Nainar0dfd4be2017-11-16 22:40:00 -08008 "hwui_pgo",
Pirama Arumuga Nainarb7913e12018-03-09 00:03:57 +00009 "hwui_lto",
Colin Crossf6298102017-04-19 15:25:25 -070010 ],
11
John Reck283bb462018-12-13 16:40:14 -080012 cpp_std: "experimental",
13
Colin Crossf6298102017-04-19 15:25:25 -070014 cflags: [
15 "-DEGL_EGLEXT_PROTOTYPES",
16 "-DGL_GLEXT_PROTOTYPES",
17 "-DATRACE_TAG=ATRACE_TAG_VIEW",
18 "-DLOG_TAG=\"OpenGLRenderer\"",
19 "-Wall",
20 "-Wno-unused-parameter",
21 "-Wunreachable-code",
22 "-Werror",
23 "-fvisibility=hidden",
24
25 // GCC false-positives on this warning, and since we -Werror that's
26 // a problem
27 "-Wno-free-nonheap-object",
Colin Crossf6298102017-04-19 15:25:25 -070028 ],
29
30 include_dirs: [
31 "external/skia/include/private",
32 "external/skia/src/core",
Colin Crossf6298102017-04-19 15:25:25 -070033 ],
34
35 product_variables: {
John Reck27294182018-07-11 11:21:09 -070036 eng: {
37 lto: {
38 never: true,
39 },
40 },
Colin Crossf6298102017-04-19 15:25:25 -070041 },
Fedor Kudasov182cbf92019-06-05 10:30:20 +010042
43 target: {
44 android: {
45 include_dirs: [
46 "external/skia/src/effects",
47 "external/skia/src/image",
48 "external/skia/src/utils",
49 "external/skia/src/gpu",
50 "external/skia/src/shaders",
51 ],
52 },
53 host: {
54 include_dirs: [
55 "external/vulkan-headers/include",
Fedor Kudasov86bd2142019-06-18 15:51:57 +010056 "frameworks/native/libs/math/include",
57 "frameworks/native/libs/ui/include",
Fedor Kudasov182cbf92019-06-05 10:30:20 +010058 ],
59 cflags: [
60 "-Wno-unused-variable",
61 ],
62 }
63 }
Colin Crossf6298102017-04-19 15:25:25 -070064}
65
66cc_defaults {
67 name: "hwui_static_deps",
68 shared_libs: [
Jerome Gaillarda02a12d2019-05-28 18:07:56 +010069 "libbase",
Colin Crossf6298102017-04-19 15:25:25 -070070 "libharfbuzz_ng",
Colin Crossf6298102017-04-19 15:25:25 -070071 "libminikin",
Colin Crossf6298102017-04-19 15:25:25 -070072 ],
Fedor Kudasov182cbf92019-06-05 10:30:20 +010073
74 target: {
75 android: {
76 shared_libs: [
77 "liblog",
78 "libcutils",
79 "libstatslog",
80 "libutils",
81 "libEGL",
82 "libGLESv1_CM",
83 "libGLESv2",
84 "libGLESv3",
85 "libvulkan",
86 "libui",
Alec Mouri22d753f2019-09-05 17:11:45 -070087 "libnativedisplay",
Derek Sollenbergere78f7c92019-07-31 15:18:47 -040088 "libnativewindow",
Fedor Kudasov182cbf92019-06-05 10:30:20 +010089 "libprotobuf-cpp-lite",
90 "libft2",
91 "libandroidfw",
92 "libcrypto",
93 "libsync",
Stan Ilievc9043812020-02-03 16:57:09 -050094 "libstatspull",
95 "libstatssocket",
Fedor Kudasov182cbf92019-06-05 10:30:20 +010096 ],
97 static_libs: [
98 "libEGL_blobCache",
Stan Ilievc9043812020-02-03 16:57:09 -050099 "libprotoutil",
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100100 ],
101 },
102 host: {
103 static_libs: [
104 "libandroidfw",
105 "libutils",
106 ],
107 }
108 }
Colin Crossf6298102017-04-19 15:25:25 -0700109}
110
111cc_defaults {
112 name: "hwui_bugreport_font_cache_usage",
Colin Crossf6298102017-04-19 15:25:25 -0700113 cflags: ["-DBUGREPORT_FONT_CACHE_USAGE"],
114}
115
116cc_defaults {
117 name: "hwui_compile_for_perf",
118 // TODO: Non-arm?
119 cflags: [
120 "-fno-omit-frame-pointer",
121 "-marm",
122 "-mapcs",
123 ],
124}
125
Pirama Arumuga Nainar0dfd4be2017-11-16 22:40:00 -0800126// Build libhwui with PGO by default.
127// Location of PGO profile data is defined in build/soong/cc/pgo.go
128// and is separate from hwui.
129// To turn it off, set ANDROID_PGO_NO_PROFILE_USE environment variable
130// or set enable_profile_use property to false.
131cc_defaults {
132 name: "hwui_pgo",
133
134 pgo: {
135 instrumentation: true,
136 profile_file: "hwui/hwui.profdata",
137 benchmarks: ["hwui"],
Zhizhou Yang58e1b782017-12-06 16:59:06 -0800138 enable_profile_use: true,
Pirama Arumuga Nainar0dfd4be2017-11-16 22:40:00 -0800139 },
140}
141
Zhizhou Yangf30f1122018-02-26 17:59:38 -0800142// Build hwui library with ThinLTO by default.
143cc_defaults {
144 name: "hwui_lto",
145 target: {
146 android: {
147 lto: {
148 thin: true,
149 },
150 },
151 },
152}
153
Colin Crossf6298102017-04-19 15:25:25 -0700154// ------------------------
Derek Sollenberger83ccff72019-10-24 11:49:54 -0400155// APEX
156// ------------------------
157
158cc_library_headers {
159 name: "android_graphics_apex_headers",
160
161 host_supported: true,
162 export_include_dirs: [
163 "apex/include",
164 ],
165 target: {
166 windows: {
167 enabled: true,
168 },
169 }
170}
171
172cc_defaults {
173 name: "android_graphics_apex",
174 host_supported: true,
175 cflags: [
176 "-Wno-unused-parameter",
177 "-Wno-non-virtual-dtor",
178 "-Wno-maybe-uninitialized",
179 "-Wno-parentheses",
180 "-Wall",
181 "-Werror",
182 "-Wno-error=deprecated-declarations",
183 "-Wunused",
184 "-Wunreachable-code",
185 ],
186
187 cppflags: ["-Wno-conversion-null"],
188
189 srcs: [
190 "apex/android_matrix.cpp",
191 "apex/android_paint.cpp",
192 "apex/android_region.cpp",
193 ],
194
195 header_libs: [ "android_graphics_apex_headers" ],
196
197 target: {
198 android: {
199 srcs: [ // sources that depend on android only libraries
200 "apex/android_bitmap.cpp",
201 "apex/android_canvas.cpp",
202 "apex/jni_runtime.cpp",
203 "apex/renderthread.cpp",
204 ],
205 },
Derek Sollenbergerc5882c42019-10-25 11:11:32 -0400206 host: {
207 srcs: [
208 "apex/LayoutlibLoader.cpp",
209 ],
210 }
Derek Sollenberger83ccff72019-10-24 11:49:54 -0400211 },
212}
213
214// ------------------------
215// Android Graphics JNI
216// ------------------------
217
218cc_library_headers {
219 name: "android_graphics_jni_headers",
220
221 host_supported: true,
222 export_include_dirs: [
223 "jni",
224 ],
225 target: {
226 windows: {
227 enabled: true,
228 },
229 }
230}
231
232cc_defaults {
233 name: "android_graphics_jni",
234 host_supported: true,
235 cflags: [
236 "-Wno-unused-parameter",
237 "-Wno-non-virtual-dtor",
238 "-Wno-maybe-uninitialized",
239 "-Wno-parentheses",
240
241 "-DGL_GLEXT_PROTOTYPES",
242 "-DEGL_EGLEXT_PROTOTYPES",
243
244 "-DU_USING_ICU_NAMESPACE=0",
245
246 "-Wall",
247 "-Werror",
248 "-Wno-error=deprecated-declarations",
249 "-Wunused",
250 "-Wunreachable-code",
251 ],
252
253 cppflags: ["-Wno-conversion-null"],
254
255 srcs: [
256 "jni/android_graphics_animation_NativeInterpolatorFactory.cpp",
257 "jni/android_graphics_animation_RenderNodeAnimator.cpp",
258 "jni/android_graphics_Canvas.cpp",
259 "jni/android_graphics_ColorSpace.cpp",
260 "jni/android_graphics_drawable_AnimatedVectorDrawable.cpp",
261 "jni/android_graphics_drawable_VectorDrawable.cpp",
262 "jni/android_graphics_HardwareRendererObserver.cpp",
263 "jni/android_graphics_Matrix.cpp",
264 "jni/android_graphics_Picture.cpp",
265 "jni/android_graphics_DisplayListCanvas.cpp",
266 "jni/android_graphics_RenderNode.cpp",
267 "jni/android_nio_utils.cpp",
268 "jni/android_util_PathParser.cpp",
269
270 "jni/Bitmap.cpp",
271 "jni/BitmapFactory.cpp",
272 "jni/ByteBufferStreamAdaptor.cpp",
273 "jni/Camera.cpp",
274 "jni/CanvasProperty.cpp",
275 "jni/ColorFilter.cpp",
276 "jni/CreateJavaOutputStreamAdaptor.cpp",
277 "jni/FontFamily.cpp",
278 "jni/FontUtils.cpp",
279 "jni/Graphics.cpp",
280 "jni/ImageDecoder.cpp",
281 "jni/Interpolator.cpp",
282 "jni/MaskFilter.cpp",
283 "jni/NinePatch.cpp",
284 "jni/NinePatchPeeker.cpp",
285 "jni/Paint.cpp",
286 "jni/PaintFilter.cpp",
287 "jni/Path.cpp",
288 "jni/PathEffect.cpp",
289 "jni/PathMeasure.cpp",
290 "jni/Picture.cpp",
Derek Sollenberger83ccff72019-10-24 11:49:54 -0400291 "jni/Shader.cpp",
292 "jni/Typeface.cpp",
293 "jni/Utils.cpp",
294 "jni/YuvToJpegEncoder.cpp",
295 "jni/fonts/Font.cpp",
296 "jni/fonts/FontFamily.cpp",
297 "jni/text/LineBreaker.cpp",
298 "jni/text/MeasuredText.cpp",
299 ],
300
301 header_libs: [ "android_graphics_jni_headers" ],
302
303 include_dirs: [
304 "external/skia/include/private",
305 "external/skia/src/codec",
306 "external/skia/src/core",
307 "external/skia/src/effects",
308 "external/skia/src/image",
309 "external/skia/src/images",
310 ],
311
312 shared_libs: [
313 "libbase",
314 "libbinder",
315 "libcutils",
316 "libharfbuzz_ng",
317 "liblog",
318 "libminikin",
319 "libnativehelper",
320 "libz",
321 "libziparchive",
322 "libjpeg",
323 ],
324
325 target: {
326 android: {
327 srcs: [ // sources that depend on android only libraries
328 "jni/AnimatedImageDrawable.cpp",
329 "jni/android_graphics_TextureLayer.cpp",
330 "jni/android_graphics_HardwareRenderer.cpp",
331 "jni/BitmapRegionDecoder.cpp",
332 "jni/GIFMovie.cpp",
333 "jni/GraphicsStatsService.cpp",
334 "jni/Movie.cpp",
335 "jni/MovieImpl.cpp",
Derek Sollenberger15da7e22020-02-14 14:16:34 -0500336 "jni/Region.cpp", // requires libbinder_ndk
Derek Sollenberger83ccff72019-10-24 11:49:54 -0400337 "jni/pdf/PdfDocument.cpp",
338 "jni/pdf/PdfEditor.cpp",
339 "jni/pdf/PdfRenderer.cpp",
340 "jni/pdf/PdfUtils.cpp",
341 ],
342 shared_libs: [
343 "libandroidfw",
Derek Sollenberger15da7e22020-02-14 14:16:34 -0500344 "libbinder_ndk",
Derek Sollenberger83ccff72019-10-24 11:49:54 -0400345 "libmediandk",
346 "libnativedisplay",
347 "libnativewindow",
348 "libstatspull",
349 "libstatssocket",
350 "libpdfium",
351 ],
352 static_libs: [
353 "libgif",
354 "libstatslog",
355 ],
356 },
357 host: {
358 cflags: [
359 "-Wno-unused-const-variable",
360 "-Wno-unused-function",
361 ],
362 static_libs: [
363 "libandroidfw",
364 ],
365 }
366 },
367}
368
369// ------------------------
Colin Crossf6298102017-04-19 15:25:25 -0700370// library
371// ------------------------
372
Derek Sollenberger83ccff72019-10-24 11:49:54 -0400373cc_library_headers {
374 name: "libhwui_internal_headers",
375
376 host_supported: true,
377 export_include_dirs: [
378 ".",
379 ],
380 header_libs: [ "android_graphics_jni_headers" ],
381 export_header_lib_headers: [ "android_graphics_jni_headers" ],
382}
383
Colin Crossf6298102017-04-19 15:25:25 -0700384cc_defaults {
385 name: "libhwui_defaults",
386 defaults: ["hwui_defaults"],
Derek Sollenbergerd938e5a2017-07-24 09:42:07 -0400387
388 whole_static_libs: ["libskia"],
389
Colin Crossf6298102017-04-19 15:25:25 -0700390 srcs: [
Fedor Kudasov86bd2142019-06-18 15:51:57 +0100391 "pipeline/skia/SkiaDisplayList.cpp",
392 "pipeline/skia/SkiaRecordingCanvas.cpp",
393 "pipeline/skia/RenderNodeDrawable.cpp",
394 "pipeline/skia/ReorderBarrierDrawables.cpp",
Fedor Kudasov666f8a52019-07-03 15:21:14 +0100395 "renderthread/Frame.cpp",
396 "renderthread/RenderTask.cpp",
397 "renderthread/TimeLord.cpp",
Derek Sollenberger2d142132018-01-22 10:25:26 -0500398 "hwui/AnimatedImageDrawable.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700399 "hwui/Bitmap.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700400 "hwui/Canvas.cpp",
Leon Scroggins III753a56f2019-12-11 11:02:15 -0500401 "hwui/ImageDecoder.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700402 "hwui/MinikinSkia.cpp",
403 "hwui/MinikinUtils.cpp",
404 "hwui/PaintImpl.cpp",
405 "hwui/Typeface.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700406 "utils/Blur.cpp",
Fedor Kudasov86bd2142019-06-18 15:51:57 +0100407 "utils/Color.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700408 "utils/LinearAllocator.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700409 "utils/VectorDrawableUtils.cpp",
Fedor Kudasov86bd2142019-06-18 15:51:57 +0100410 "AnimationContext.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700411 "Animator.cpp",
Fedor Kudasov86bd2142019-06-18 15:51:57 +0100412 "AnimatorManager.cpp",
413 "CanvasTransform.cpp",
414 "DamageAccumulator.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700415 "Interpolator.cpp",
Fedor Kudasov86bd2142019-06-18 15:51:57 +0100416 "LightingInfo.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700417 "Matrix.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700418 "PathParser.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700419 "Properties.cpp",
420 "PropertyValuesAnimatorSet.cpp",
421 "PropertyValuesHolder.cpp",
Fedor Kudasov86bd2142019-06-18 15:51:57 +0100422 "RecordingCanvas.cpp",
423 "RenderNode.cpp",
424 "RenderProperties.cpp",
Fedor Kudasov09cfce02019-07-04 09:41:13 +0100425 "RootRenderNode.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700426 "SkiaCanvas.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700427 "VectorDrawable.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700428 ],
429
Kweku Adams228b6d22018-04-12 13:09:04 -0700430 proto: {
431 export_proto_headers: true,
432 },
433
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100434 target: {
435 android: {
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100436 srcs: [
Jerome Gaillardf9a4dc42020-01-29 15:23:26 +0000437 "hwui/AnimatedImageThread.cpp",
Stan Ilieve0fae232020-01-07 17:21:49 -0500438 "pipeline/skia/ATraceMemoryDump.cpp",
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100439 "pipeline/skia/GLFunctorDrawable.cpp",
440 "pipeline/skia/LayerDrawable.cpp",
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100441 "pipeline/skia/ShaderCache.cpp",
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100442 "pipeline/skia/SkiaMemoryTracer.cpp",
443 "pipeline/skia/SkiaOpenGLPipeline.cpp",
444 "pipeline/skia/SkiaPipeline.cpp",
445 "pipeline/skia/SkiaProfileRenderer.cpp",
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100446 "pipeline/skia/SkiaVulkanPipeline.cpp",
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100447 "pipeline/skia/VkFunctorDrawable.cpp",
448 "pipeline/skia/VkInteropFunctorDrawable.cpp",
449 "renderstate/RenderState.cpp",
450 "renderthread/CacheManager.cpp",
451 "renderthread/CanvasContext.cpp",
452 "renderthread/DrawFrameTask.cpp",
453 "renderthread/EglManager.cpp",
454 "renderthread/ReliableSurface.cpp",
455 "renderthread/VulkanManager.cpp",
456 "renderthread/VulkanSurface.cpp",
457 "renderthread/RenderProxy.cpp",
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100458 "renderthread/RenderThread.cpp",
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100459 "service/GraphicsStatsService.cpp",
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100460 "thread/CommonPool.cpp",
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100461 "utils/GLUtils.cpp",
462 "utils/StringUtils.cpp",
Stan Ilievaaa9e832019-09-17 14:07:23 -0400463 "AutoBackendTextureRelease.cpp",
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100464 "DeferredLayerUpdater.cpp",
465 "DeviceInfo.cpp",
466 "FrameInfo.cpp",
467 "FrameInfoVisualizer.cpp",
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100468 "HardwareBitmapUploader.cpp",
469 "HWUIProperties.sysprop",
470 "JankTracker.cpp",
471 "Layer.cpp",
472 "LayerUpdateQueue.cpp",
473 "ProfileData.cpp",
474 "ProfileDataContainer.cpp",
475 "Readback.cpp",
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100476 "TreeInfo.cpp",
477 "WebViewFunctorManager.cpp",
478 "protos/graphicsstats.proto",
479 ],
480
481 // Allow implicit fallthroughs in HardwareBitmapUploader.cpp until they are fixed.
482 cflags: ["-Wno-implicit-fallthrough"],
483 },
484 host: {
Fedor Kudasov86bd2142019-06-18 15:51:57 +0100485 srcs: [
486 "utils/HostColorSpace.cpp",
487 ],
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100488 export_static_lib_headers: [
489 "libarect",
490 ],
491 }
492 }
Colin Crossf6298102017-04-19 15:25:25 -0700493}
494
495cc_library {
496 name: "libhwui",
Fedor Kudasov182cbf92019-06-05 10:30:20 +0100497 host_supported: true,
Chris Craikd17b63c2017-06-01 10:45:36 -0700498 defaults: [
499 "libhwui_defaults",
Derek Sollenberger83ccff72019-10-24 11:49:54 -0400500 "android_graphics_apex",
501 "android_graphics_jni",
Zhizhou Yang17371ec2017-10-13 11:42:13 -0700502 ],
Derek Sollenberger83ccff72019-10-24 11:49:54 -0400503 export_header_lib_headers: ["android_graphics_apex_headers"],
Colin Crossf6298102017-04-19 15:25:25 -0700504}
505
Colin Crossf6298102017-04-19 15:25:25 -0700506cc_library_static {
John Reck23462d82019-05-29 16:55:06 -0700507 name: "libhwui_static",
Colin Crossf6298102017-04-19 15:25:25 -0700508 defaults: [
509 "libhwui_defaults",
Colin Crossf6298102017-04-19 15:25:25 -0700510 ],
Colin Crossf6298102017-04-19 15:25:25 -0700511}
512
513cc_defaults {
514 name: "hwui_test_defaults",
515 defaults: ["hwui_defaults"],
516 test_suites: ["device-tests"],
Alec Mouri680414e2020-01-28 09:22:33 -0800517 target: {
518 android: {
519 shared_libs: [
520 "libgui",
521 ],
522 }
523 },
Colin Crossf6298102017-04-19 15:25:25 -0700524 srcs: [
525 "tests/common/scenes/*.cpp",
526 "tests/common/LeakChecker.cpp",
527 "tests/common/TestListViewSceneBase.cpp",
528 "tests/common/TestContext.cpp",
529 "tests/common/TestScene.cpp",
530 "tests/common/TestUtils.cpp",
531 ],
532}
533
534// ------------------------
535// unit tests
536// ------------------------
537
538cc_test {
539 name: "hwui_unit_tests",
540 defaults: ["hwui_test_defaults"],
541
542 static_libs: [
543 "libgmock",
John Reck23462d82019-05-29 16:55:06 -0700544 "libhwui_static",
Colin Crossf6298102017-04-19 15:25:25 -0700545 ],
Tej Singhbb8554a2018-01-26 11:59:14 -0800546 shared_libs: [
547 "libmemunreachable",
Tej Singhbb8554a2018-01-26 11:59:14 -0800548 ],
Colin Crossf6298102017-04-19 15:25:25 -0700549
550 srcs: [
551 "tests/unit/main.cpp",
Derek Sollenbergerf9e45d12017-06-01 13:07:39 -0400552 "tests/unit/CacheManagerTests.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700553 "tests/unit/CanvasContextTests.cpp",
John Reck322b8ab2019-03-14 13:15:28 -0700554 "tests/unit/CommonPoolTests.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700555 "tests/unit/DamageAccumulatorTests.cpp",
556 "tests/unit/DeferredLayerUpdaterTests.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700557 "tests/unit/FatVectorTests.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700558 "tests/unit/GraphicsStatsServiceTests.cpp",
559 "tests/unit/LayerUpdateQueueTests.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700560 "tests/unit/LinearAllocatorTests.cpp",
561 "tests/unit/MatrixTests.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700562 "tests/unit/PathInterpolatorTests.cpp",
563 "tests/unit/RenderNodeDrawableTests.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700564 "tests/unit/RenderNodeTests.cpp",
565 "tests/unit/RenderPropertiesTests.cpp",
John Reck700079e2019-02-19 10:38:50 -0800566 "tests/unit/RenderThreadTests.cpp",
Stan Ilievd495f432017-10-09 15:49:32 -0400567 "tests/unit/ShaderCacheTests.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700568 "tests/unit/SkiaBehaviorTests.cpp",
569 "tests/unit/SkiaDisplayListTests.cpp",
570 "tests/unit/SkiaPipelineTests.cpp",
571 "tests/unit/SkiaRenderPropertiesTests.cpp",
572 "tests/unit/SkiaCanvasTests.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700573 "tests/unit/StringUtilsTests.cpp",
574 "tests/unit/TestUtilsTests.cpp",
John Reckf8441e62017-10-23 13:10:41 -0700575 "tests/unit/ThreadBaseTests.cpp",
576 "tests/unit/TypefaceTests.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700577 "tests/unit/VectorDrawableTests.cpp",
John Reck283bb462018-12-13 16:40:14 -0800578 "tests/unit/WebViewFunctorManagerTests.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700579 ],
580}
581
582// ------------------------
583// Macro-bench app
584// ------------------------
585
586cc_benchmark {
587 name: "hwuimacro",
588 defaults: ["hwui_test_defaults"],
589
John Reck23462d82019-05-29 16:55:06 -0700590 static_libs: ["libhwui"],
Tej Singhbb8554a2018-01-26 11:59:14 -0800591 shared_libs: [
592 "libmemunreachable",
Tej Singhbb8554a2018-01-26 11:59:14 -0800593 ],
Colin Crossf6298102017-04-19 15:25:25 -0700594
595 srcs: [
596 "tests/macrobench/TestSceneRunner.cpp",
597 "tests/macrobench/main.cpp",
598 ],
599}
600
601// ------------------------
602// Micro-bench app
603// ---------------------
604
605cc_benchmark {
606 name: "hwuimicro",
607 defaults: ["hwui_test_defaults"],
608
John Reck23462d82019-05-29 16:55:06 -0700609 static_libs: ["libhwui_static"],
Tej Singhbb8554a2018-01-26 11:59:14 -0800610 shared_libs: [
611 "libmemunreachable",
Tej Singhbb8554a2018-01-26 11:59:14 -0800612 ],
Colin Crossf6298102017-04-19 15:25:25 -0700613
614 srcs: [
615 "tests/microbench/main.cpp",
616 "tests/microbench/DisplayListCanvasBench.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700617 "tests/microbench/LinearAllocatorBench.cpp",
618 "tests/microbench/PathParserBench.cpp",
619 "tests/microbench/RenderNodeBench.cpp",
Colin Crossf6298102017-04-19 15:25:25 -0700620 ],
621}
Pirama Arumuga Nainarbc1e1772017-11-17 11:32:16 -0800622
623// ----------------------------------------
624// Phony target to build benchmarks for PGO
625// ----------------------------------------
626
627phony {
628 name: "pgo-targets-hwui",
629 required: [
630 "hwuimicro",
631 "hwuimacro",
632 ]
633}