Dmitry Skiba | afc6c28 | 2024-12-02 06:04:29 +0000 | [diff] [blame^] | 1 | #!/vendor/bin/sh |
| 2 | |
| 3 | # This script delays experiments by the specified amount of seconds. The delay is not needed for |
| 4 | # the normal operation, but becomes essential for the rare case (which "should not happen") where |
| 5 | # an experiment causes really bad issues (e.g. crashes the kernel). In such case the delay gives |
| 6 | # GMSCore an opportunity to fetch fresh experiments snapshot (with the bad experiment disabled). |
| 7 | # |
| 8 | # See go/pixel-perf-experiment-whatif for more info. |
| 9 | |
| 10 | delay_seconds="$1" |
| 11 | |
| 12 | if [ -n "$delay_seconds" ]; then |
| 13 | sleep "$delay_seconds" |
| 14 | /vendor/bin/setprop vendor.perf.allow_experiments 1 |
| 15 | fi |