Create data/ dir, move cli, 9p and readfile there.

This commit is contained in:
Ciro Santilli
2018-04-06 01:02:41 +01:00
parent d23e7ee183
commit 9405b35ad2
7 changed files with 36 additions and 31 deletions

View File

@@ -117,10 +117,10 @@ It gets annoying to retype `-a aarch64` for every single command, or to remember
So simplify that, do:
....
cp cli.gitignore.example cli.gitignore
cp cli.example data/cli
....
and then edit the `cli.gitignore` file to your needs.
and then edit the `data/cli` file to your needs.
That file is used to pass extra command line arguments to most of our utilities.
@@ -1960,7 +1960,7 @@ TODO performance compared to NFS.
As usual, we have already set everything up for you. On host:
....
cd 9p
cd data/9p
uname -a > host
....
@@ -2401,17 +2401,17 @@ arch=aarch64
# Generate a checkpoint after Linux boots.
# The boot takes a while, be patient young Padawan.
printf 'm5 exit' >readfile.gitignore
printf 'm5 exit' >data/readfile
./run -a "$arch" -g -E 'm5 checkpoint;m5 readfile > a.sh;sh a.sh'
# Restore the checkpoint, and run the benchmark with parameter 1.000.
# We skip the boot completely, saving time!
printf 'm5 resetstats;dhrystone 1000;m5 exit' >readfile.gitignore
printf 'm5 resetstats;dhrystone 1000;m5 exit' >data/readfile
./run -a "$arch" -g -- -r 1
./gem5-stat -a "$arch"
# Now with another parameter 10.000.
printf 'm5 resetstats;dhrystone 10000;m5 exit' >readfile.gitignore
printf 'm5 resetstats;dhrystone 10000;m5 exit' >data/readfile
./run -a "$arch" -g -- -r 1
./gem5-stat -a "$arch"
....
@@ -3036,11 +3036,11 @@ The problem is that after the checkpoint, the memory and disk states are fixed,
There is however one loophole: <<m5-readfile>>, which reads whatever is present on the host, so we can do it like:
....
printf 'echo "setup run";m5 exit' >readfile.gitignore
printf 'echo "setup run";m5 exit' >data/readfile
./run -a aarch64 -g -E 'm5 checkpoint;m5 readfile > a.sh;sh a.sh'
printf 'echo "first benchmark";m5 exit' >readfile.gitignore
printf 'echo "first benchmark";m5 exit' >data/readfile
./run -a aarch64 -g -- -r 1
printf 'echo "second benchmark";m5 exit' >readfile.gitignore
printf 'echo "second benchmark";m5 exit' >data/readfile
./run -a aarch64 -g -- -r 1
....
@@ -3382,7 +3382,7 @@ https://stackoverflow.com/questions/49516399/how-to-use-m5-readfile-and-m5-execf
Host:
....
date > readfile.gitignore
date > data/readfile
....
Guest:
@@ -3397,7 +3397,7 @@ Host:
....
printf '#!/bin/sh
echo asdf' > readfile.gitignore
echo asdf' > data/readfile
....
Guest:
@@ -3973,6 +3973,9 @@ then `dtc a.dts` gives:
=== Directory structure
* `/data`: gitignored user created data. Deleting this might lead to loss of data. Of course, if something there becomes is important enough to you, git track it.
* `/out`: gitignored Build outputs. You won't lose data by deleting this folder since everything there can be re-generated, only time.
:leveloffset: +3
include::buildroot_patches/README.adoc[]