Mace-cl-compiled-program.bin _hot_ -
Which or device models you are targeting?
: On Android devices, it is often stored in temporary directories such as /data/local/tmp/mace_run/ or within the application's internal storage cache.
But then, the terminal output began to scroll with warnings. The binary—the very thing they had spent months "tuning"—was accessing memory addresses outside the expected buffer. It wasn't a crash. It was an expansion.
When MACE runs a neural network model on a GPU for the first time, it must compile the model's operations (like convolutions and activations) into machine code that the specific GPU can understand. This compilation process, called JIT (Just-In-Time) compilation, can be time-consuming and varies across different devices. Here's a simplified breakdown of the process: mace-cl-compiled-program.bin
Ensure your app has storage write permissions enabled in Android Settings.
If the file system lacks adequate read/write permissions for that directory, MACE will fail to save the cache and will re-compile the kernels on every single launch, draining battery life and performance. 2. The CL_INVALID_WORK_GROUP_SIZE Crash
Significantly reduces model startup and inference time. Which or device models you are targeting
Are you looking to using MACE, or did you encounter this file during a security/storage audit ? Let me know your main goal, and I can provide tailored steps. Share public link
Therefore, deleting the file to save storage space is generally ineffective, as it will simply reappear. Technical Summary for Developers
When an application wants to run a neural network on a GPU, it does not send the raw model to the GPU. Instead, it sends a kernel written in OpenCL C (similar to C99). The GPU driver must compile this source code into machine code specific to that exact GPU model (Adreno, Mali, or PowerVR). The binary—the very thing they had spent months
You can check which app owns the file using ls -l or, on Android, see the parent directory.
To interact with various mobile GPUs (such as Qualcomm Adreno or ARM Mali), MACE relies on . OpenCL acts as an abstraction layer, allowing developers to write unified code that executes across different graphics hardware. However, because every mobile system-on-chip (SoC) architecture is distinct, OpenCL code must be compiled into machine code specifically tailored to the target device's GPU. Why the mace-cl-compiled-program.bin File Exists
Verify the target directory ( /storage/emulated/0/mace/ ) is created before the MACE engine initializes. 3. Compatibility Issues
: Especially on Xiaomi, Redmi, POCO, and Black Shark devices, where MACE powers AI scene detection, night mode, and portrait blur.
You will typically find this file in app-specific directories. Common paths include: