Skip to content

Commit 1d498da

Browse files
committed
Move Gradle Home and Gradle Profiler directories up.
We've noticed a 5-10% performance improvement in certain scenarios because of the way file system watching will watch the entire directory. It is also not a typical setup that the gradle-user-home is also in the project directory. Because of this, the `output` directory in the root folder has been renamed to `results` to separate build outputs from results.
1 parent 04750e8 commit 1d498da

File tree

5 files changed

+11
-8
lines changed

5 files changed

+11
-8
lines changed

mobile_app1/.gitignore .gitignore

+3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
1+
.DS_Store
2+
13
build/
24
.gradle
35
gradle-user-home
46
profile-out-*
57

8+
.java-version

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ Benchmark scenario are as follow :
7373

7474
#### Current results
7575

76-
![apps_presidio_helix_app results](/output/mobile_app1.png)
76+
![apps_presidio_helix_app results](/results/mobile_app1.png)
7777

7878
### License
7979

mobile_app1/benchmark.sh

+7-7
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ if ! [ -x "$(command -v bazel)" ]; then
66
fi
77

88
if [[ -z "$GRADLE_PROFILER" ]]; then
9-
if ! [ -d "gradle-profiler" ]
9+
if ! [ -d "../gradle-profiler" ]
1010
then
1111
echo "Installing Gradle profiler.."
12-
git clone https://github.com/sunyal/gradle-profiler.git
13-
cd gradle-profiler || exit
12+
git clone https://github.com/sunyal/gradle-profiler.git ../gradle-profiler
13+
cd ../gradle-profiler || exit
1414

1515
# gradle dist in repo points to an obsolete snapshot.
1616
sed -i -e 's/4.8-20180417000132+0000/4.8/g' gradle/wrapper/gradle-wrapper.properties
@@ -20,7 +20,7 @@ if [[ -z "$GRADLE_PROFILER" ]]; then
2020
echo Grade Profile installed successful! Please restart benchmark.
2121
exit 0
2222
fi
23-
GRADLE_PROFILER=./gradle-profiler/build/install/gradle-profiler/bin/gradle-profiler
23+
GRADLE_PROFILER=../gradle-profiler/build/install/gradle-profiler/bin/gradle-profiler
2424
else
2525
if ! [ -e "$GRADLE_PROFILER" ]
2626
then
@@ -30,10 +30,10 @@ else
3030
fi
3131

3232
BASEDIR=$(dirname "$0")
33-
GRADLE_VERSION=6.7
33+
GRADLE_VERSION=6.7.1
3434

3535
timestampDir=$(date +"%Y%m%d_%H%M%S")
36-
outputDir=output/$timestampDir
36+
outputDir=../output/$timestampDir
3737
iterations=2
3838
warmups=1
3939

@@ -45,7 +45,7 @@ mkdir -p "$outputDir"/
4545
$GRADLE_PROFILER --benchmark --gradle-version $GRADLE_VERSION $2 --iterations=$iterations --warmups=$warmups --output-dir="$outputDir"/buck --scenario-file "$BASEDIR/performance.scenarios" --project-dir . --buck
4646

4747
# shellcheck disable=SC2086
48-
$GRADLE_PROFILER --benchmark --gradle-version $GRADLE_VERSION $2 --iterations=$iterations --warmups=$warmups --output-dir="$outputDir"/gradle --scenario-file "$BASEDIR/performance.scenarios" --project-dir .
48+
$GRADLE_PROFILER --benchmark --gradle-version $GRADLE_VERSION $2 --iterations=$iterations --warmups=$warmups --output-dir="$outputDir"/gradle --scenario-file "$BASEDIR/performance.scenarios" --project-dir . --gradle-user-home ../gradle-user-home
4949

5050
# shellcheck disable=SC2086
5151
$GRADLE_PROFILER --benchmark --gradle-version $GRADLE_VERSION $2 --iterations=$iterations --warmups=$warmups --output-dir="$outputDir"/bazel --scenario-file "$BASEDIR/performance.scenarios" --project-dir . --bazel
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)