1cc_library_shared { 2 name: "libRSCpuRef", 3 defaults: ["libbcc-targets"], 4 vendor_available: true, 5 native_bridge_supported: true, 6 vndk: { 7 enabled: true, 8 support_system_process: true, 9 }, 10 11 srcs: [ 12 "rsCpuCore.cpp", 13 "rsCpuExecutable.cpp", 14 "rsCpuScript.cpp", 15 "rsCpuRuntimeMath.cpp", 16 "rsCpuScriptGroup.cpp", 17 "rsCpuScriptGroup2.cpp", 18 "rsCpuIntrinsic.cpp", 19 "rsCpuIntrinsic3DLUT.cpp", 20 "rsCpuIntrinsicBLAS.cpp", 21 "rsCpuIntrinsicBlend.cpp", 22 "rsCpuIntrinsicBlur.cpp", 23 "rsCpuIntrinsicColorMatrix.cpp", 24 "rsCpuIntrinsicConvolve3x3.cpp", 25 "rsCpuIntrinsicConvolve5x5.cpp", 26 "rsCpuIntrinsicHistogram.cpp", 27 "rsCpuIntrinsicResize.cpp", 28 "rsCpuIntrinsicLUT.cpp", 29 "rsCpuIntrinsicYuvToRGB.cpp", 30 ], 31 32 arch: { 33 arm64: { 34 cflags: [ 35 "-DARCH_ARM_USE_INTRINSICS", 36 "-DARCH_ARM64_USE_INTRINSICS", 37 "-DARCH_ARM64_HAVE_NEON", 38 ], 39 40 srcs: [ 41 "rsCpuIntrinsics_advsimd_3DLUT.S", 42 "rsCpuIntrinsics_advsimd_Convolve.S", 43 "rsCpuIntrinsics_advsimd_Blur.S", 44 "rsCpuIntrinsics_advsimd_ColorMatrix.S", 45 "rsCpuIntrinsics_advsimd_Resize.S", 46 "rsCpuIntrinsics_advsimd_YuvToRGB.S", 47 "rsCpuIntrinsics_advsimd_Blend.S", 48 ], 49 }, 50 51 arm: { 52 cflags: [ 53 "-DARCH_ARM_HAVE_VFP", 54 "-DARCH_ARM_USE_INTRINSICS", 55 ], 56 57 srcs: [ 58 "rsCpuIntrinsics_neon_3DLUT.S", 59 "rsCpuIntrinsics_neon_Blend.S", 60 "rsCpuIntrinsics_neon_Blur.S", 61 "rsCpuIntrinsics_neon_Convolve.S", 62 "rsCpuIntrinsics_neon_ColorMatrix.S", 63 "rsCpuIntrinsics_neon_Resize.S", 64 "rsCpuIntrinsics_neon_YuvToRGB.S", 65 ], 66 67 asflags: ["-mfpu=neon"], 68 69 neon: { 70 cflags: [ 71 "-DARCH_ARM_HAVE_NEON", 72 ], 73 }, 74 }, 75 76 x86: { 77 cflags: ["-DARCH_X86_HAVE_SSSE3"], 78 srcs: ["rsCpuIntrinsics_x86.cpp"], 79 }, 80 x86_64: { 81 cflags: ["-DARCH_X86_HAVE_SSSE3"], 82 srcs: ["rsCpuIntrinsics_x86.cpp"], 83 avx2: { 84 cflags: ["-DARCH_X86_HAVE_AVX2", "-mavx2", "-mfma"], 85 }, 86 }, 87 }, 88 89 shared_libs: [ 90 "libRS_internal", 91 "libc++", 92 "liblog", 93 "libz", 94 95 "libbcinfo", 96 "libblas", 97 ], 98 static_libs: ["libbnnmlowp"], 99 header_libs: [ 100 "libutils_headers", 101 "libhardware_headers", 102 ], 103 104 include_dirs: [ 105 "frameworks/compile/libbcc/include", 106 "frameworks/rs", 107 ], 108 109 cflags: [ 110 "-Werror", 111 "-Wall", 112 "-Wextra", 113 "-Wno-unused-parameter", 114 "-Wno-unused-variable", 115 ], 116 117 product_variables: { 118 pdk: { 119 // Not building RenderScript modules in PDK builds, as libmediandk 120 // is not available in PDK. 121 enabled: false, 122 }, 123 }, 124} 125