# Performance

#### Mechanism

* **Tools Used**: PACT (Apxor’s in-house performance monitoring tool)
* **Benchmarking candidate**: Firebase SDK
* **Duration of each run**: 10 minutes
* **Total no. of runs**: 10

#### Impact on App Size

| S.No. | Description       | App Size              |
| ----- | ----------------- | --------------------- |
| 1     | Standalone App    | 3.8 MB                |
| 2     | App + NudgesSDK   | 4.55 MB **(+750 KB)** |
| 3     | App + FirebaseSDK | 4.6 MB **(+800 KB)**  |

#### CPU Bechmarking

The following matrix consists of **Device vs %CPU consumed**

<table><thead><tr><th width="159">Device</th><th width="155" align="center">Standalone App</th><th width="224" align="center">App + ApxorNudgesSDK</th><th align="center">App + FirebaseSDK</th></tr></thead><tbody><tr><td><strong>OnePlus 3</strong><br>(Android 9)</td><td align="center">23.12</td><td align="center">31.6</td><td align="center">49.08</td></tr><tr><td><strong>OnePlus 7</strong><br>(Android 10)</td><td align="center">8.62</td><td align="center">10.70</td><td align="center">12.43</td></tr><tr><td><strong>Xiaomi Mi A1</strong><br>(Android 9)</td><td align="center">24.23</td><td align="center">30.40</td><td align="center">35.94</td></tr><tr><td><strong>Xiaomi Mi A3</strong><br>(Android 10)</td><td align="center">6.69</td><td align="center">8.25</td><td align="center">7.52</td></tr></tbody></table>

<mark style="background-color:yellow;">**Note**</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">On an average, for the high end devices (OnePlus 5 and above) with ApxorNudgesSDK integrated, CPU usage would increase by</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">**2%**</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">while with FirebaseSDK it would increase by</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">**4-5%**</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">.</mark>

<mark style="background-color:yellow;">In low end devices with ApxorNudgesSDK integrated, CPU usage would increase by</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">**8%**</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">while for firebase the CPU usage would increase by</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">**20%**</mark><mark style="background-color:yellow;">.</mark>

#### Memory Bechmarking

The following matrix consists of **Device vs Memory Usage in KB**

<table><thead><tr><th width="226.33333333333331">Device</th><th align="center">App + ApxorNudgesSDK</th><th align="center">App + FirebaseSDK</th></tr></thead><tbody><tr><td><strong>OnePlus 3</strong><br>(Android 9)</td><td align="center">24.84</td><td align="center">28.92</td></tr><tr><td><strong>OnePlus 7</strong><br>(Android 10)</td><td align="center">24.62</td><td align="center">29.38</td></tr><tr><td><strong>Xiaomi Mi A1</strong><br>(Android 9)</td><td align="center">18.10</td><td align="center">24.18</td></tr><tr><td><strong>Xiaomi Mi A3</strong><br>(Android 10)</td><td align="center">20.11</td><td align="center">26.90</td></tr></tbody></table>

<mark style="background-color:yellow;">**Note**</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">For ApxorNudgesSDK with all the plugins installed, the memory increases by</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">**30 KB**</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">which is on par with the Firebase SDK that has seen an increase by</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">**29 KB**</mark><mark style="background-color:yellow;">.</mark>

#### Battery Usage Bechmarking

The following matrix consists of **Device vs %Battery Drain**

<table><thead><tr><th width="173">Device</th><th width="171" align="center">Standalone App</th><th width="219" align="center">App + ApxorNudgesSDK</th><th align="center">App + FirebaseSDK</th></tr></thead><tbody><tr><td><strong>OnePlus 3</strong><br>(Android 9)</td><td align="center">0.15</td><td align="center">0.19</td><td align="center">0.29</td></tr><tr><td><strong>OnePlus 7</strong><br>(Android 10)</td><td align="center">0.03</td><td align="center">0.05</td><td align="center">0.05</td></tr><tr><td><strong>Xiaomi Mi A1</strong><br>(Android 9)</td><td align="center">0.18</td><td align="center">0.23</td><td align="center">0.32</td></tr><tr><td><strong>Xiaomi Mi A3</strong><br>(Android 10)</td><td align="center">0.12</td><td align="center">0.13</td><td align="center">0.13</td></tr></tbody></table>

<mark style="background-color:yellow;">**Note**</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">For ApxorNudgesSDK with all the plugins installed on an average the battery drain % would be</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">**0.03%**</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">while with the FirebaseSDK installed it is recorded to be around</mark> <mark style="background-color:yellow;"></mark><mark style="background-color:yellow;">**0.06%**</mark><mark style="background-color:yellow;">.</mark>
