File tree Expand file tree Collapse file tree 4 files changed +30
-5
lines changed Expand file tree Collapse file tree 4 files changed +30
-5
lines changed Original file line number Diff line number Diff line change @@ -353,13 +353,24 @@ To get a terminal, either open a new shell and run:
353
353
./gem5-shell
354
354
....
355
355
356
- or if you are inside tmux, which I highly recommend, just run gem5 with:
356
+ The only way to exit the shell is to kill the gem5 on the previous shell
357
+
358
+ If you are inside tmux, which I highly recommend, just run gem5 with:
357
359
358
360
....
359
361
./run --gem5 --tmux
360
362
....
361
363
362
- This will open up a split terminal by default so that you can see both the gem5 stdout and the terminal. See also: <<tmux-gem5>>
364
+ This will open up a split terminal by default so that you can see both the gem5 stdout and the terminal. See also: <<tmux-gem5>>.
365
+
366
+ At the end of boot, it might not be very clear that you have the shell since some <<printk>> messages may appear in front of the prompt like this:
367
+
368
+ ....
369
+ # <6>[ 1.215329] clocksource: tsc: mask: 0xffffffffffffffff max_cycles: 0x1cd486fa865, max_idle_ns: 440795259574 ns
370
+ <6>[ 1.215351] clocksource: Switched to clocksource tsc
371
+ ....
372
+
373
+ but if you look closely, the `PS1` prompt marker `#` is there already, just hit enter and a clear prompt line will appear.
363
374
364
375
If you forgot to open the shell and gem5 exit, you can inspect the terminal output post-mortem at:
365
376
Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ import os
6
6
import pathlib
7
7
import shutil
8
8
import subprocess
9
+ import time
9
10
10
11
import common
11
12
@@ -23,6 +24,7 @@ disks_dir = os.path.join(common.gem5_system_dir, 'disks')
23
24
if args .clean :
24
25
common .rmrf (common .gem5_build_dir )
25
26
else :
27
+ start_time = time .time ()
26
28
os .makedirs (binaries_dir , exist_ok = True )
27
29
os .makedirs (disks_dir , exist_ok = True )
28
30
if not os .path .exists (os .path .join (common .gem5_src_dir , '.git' )):
81
83
term_src_dir = os .path .join (common .gem5_src_dir , 'util/term' )
82
84
subprocess .check_call (['make' , '-C' , term_src_dir ])
83
85
shutil .copy2 (os .path .join (term_src_dir , 'm5term' ), common .gem5_m5term )
86
+ end_time = time .time ()
87
+ common .print_time (end_time - start_time )
Original file line number Diff line number Diff line change 3
3
import multiprocessing
4
4
import os
5
5
import subprocess
6
+ import time
6
7
7
8
import common
8
9
@@ -18,6 +19,7 @@ args = common.setup(parser)
18
19
if args .clean :
19
20
common .rmrf (common .qemu_build_dir )
20
21
else :
22
+ start_time = time .time ()
21
23
os .makedirs (common .qemu_build_dir , exist_ok = True )
22
24
subprocess .check_call (
23
25
[
37
39
# TODO factor with build.
38
40
'-j' , str (multiprocessing .cpu_count ()),
39
41
],
40
- cwd = common .qemu_build_dir
42
+ cwd = common .qemu_build_dir ,
43
+ extra_env = {'PATH' : '/usr/lib/ccache:' + os .environ ['PATH' ]},
41
44
)
45
+ end_time = time .time ()
46
+ common .print_time (end_time - start_time )
Original file line number Diff line number Diff line change 1
1
#!/usr/bin/env python3
2
2
3
3
import os
4
+ import re
4
5
import shlex
5
6
import subprocess
6
7
import sys
7
- import re
8
+ import time
8
9
9
10
import common
10
11
@@ -463,4 +464,8 @@ Run QEMU with VNC instead of the default SDL. Connect to it with:
463
464
if __name__ == '__main__' :
464
465
parser = get_argparse ()
465
466
args = common .setup (parser )
466
- sys .exit (main (args ))
467
+ start_time = time .time ()
468
+ exit_status = main (args )
469
+ end_time = time .time ()
470
+ common .print_time (end_time - start_time )
471
+ sys .exit (exit_status )
You can’t perform that action at this time.
0 commit comments