Update docs w/ fixes

This commit is contained in:
abejgonzalez 2023-03-05 17:40:33 -08:00
parent 7ef1f4a5bb
commit d826776d6c
4 changed files with 64 additions and 16 deletions

View File

@ -20,7 +20,7 @@ We require the following programs/packages installed from the Xilinx website in
* Xilinx U250 board package (corresponding with Vitis 2022.1)
Setup Validation
----------------
~~~~~~~~~~~~~~~~
After installing the U250 FPGA using the Xilinx instructions and installing the specific versions of Vitis/XRT, let's verify that the U250 FPGA can be used for emulations.
Ensure that you can run the following XRT commands without errors:
@ -35,6 +35,26 @@ The ``xbutil validate`` command runs simple tests to ensure that the FPGA can be
.. Warning:: Anytime the host computer is rebooted you may need to re-run parts of the setup process (i.e. re-flash the shell).
Before continuing to FireSim simulations after a host computer reboot, ensure that the previously mentioned ``xbutil`` command is successful.
Finally, ensure that the XRT/Vitis tools are sourced in your shell setup (i.e. ``.bashrc`` and or ``.bash_profile``) so that any shell can use the corresponding programs.
The environment variables should be visible to any non-interactive shells that are spawned.
You can check this by ensuring that the output of the following command shows that the XRT/Vitis tools are present in the environment variables (i.e. ``XILINX_XRT``):
.. parsed-literal::
ssh localhost printenv
Other Miscellaneous Setup
-------------------------
Additionally, you should be able to run ``ssh localhost`` without needing a password.
The FireSim manager program runs all commands by ``ssh``-ing into a BuildFarm/RunFarm machine given an IP address then running the command.
To do so non-interactively it needs passwordless access to the machines to build/run on.
In the case of this tutorial, our local machine or ``localhost``.
Finally, if you are running this tutorial without ``sudo`` access you should also install the ``guestmount`` program and ensure it runs properly.
This is needed by a variety of FireSim programs that mount disk images to copy in/out results of simulations.
Most likely you will need to follow the instructions here to ensure ``guestmount`` doesn't error: https://askubuntu.com/questions/1046828/how-to-run-libguestfs-tools-tools-such-as-virt-make-fs-without-sudo.
Setting up the FireSim Repo
---------------------------
@ -53,7 +73,7 @@ Run:
.. parsed-literal::
./scripts/machine-launch-script.sh
source ./scripts/machine-launch-script.sh
This will install Miniforge Conda (https://github.com/conda-forge/miniforge) and create a default environment called ``firesim`` that is used.
**Ensure that you log out of the machine / exit out of the terminal after this step so that ``.bashrc`` modifications can apply**.

View File

@ -28,9 +28,9 @@ distribution. You can do this like so:
This process will take about 10 to 15 minutes on a ``c5.4xlarge`` instance.
Once this is completed, you'll have the following files:
- ``firesim/sw/firesim-software/images/br-base-bin`` - a bootloader + Linux
- ``firesim/sw/firesim-software/images/br-base/br-base-bin`` - a bootloader + Linux
kernel image for the nodes we will simulate.
- ``firesim/sw/firesim-software/images/br-base.img`` - a disk image for
- ``firesim/sw/firesim-software/images/br-base/br-base.img`` - a disk image for
each the nodes we will simulate
These files will be used to form base images to either build more complicated
@ -500,4 +500,3 @@ check-out some of the advanced features of FireSim in the sidebar to the left
(for example, we expect that many people will be interested in the ability to
automatically run the SPEC17 benchmarks: :ref:`spec-2017`), or you can continue
on with the cluster simulation tutorial.

View File

@ -1,5 +1,3 @@
.. _onprem-single-node-sim:
Running a Single Node Simulation
===================================
@ -26,9 +24,9 @@ distribution. You can do this like so:
Once this is completed, you'll have the following files:
- ``firesim/sw/firesim-software/images/br-base-bin`` - a bootloader + Linux
- ``firesim/sw/firesim-software/images/br-base/br-base-bin`` - a bootloader + Linux
kernel image for the nodes we will simulate.
- ``firesim/sw/firesim-software/images/br-base.img`` - a disk image for
- ``firesim/sw/firesim-software/images/br-base/br-base.img`` - a disk image for
each the nodes we will simulate
These files will be used to form base images to either build more complicated
@ -150,7 +148,7 @@ First, we will tell the manager to launch our Run Farm with a single machine cal
::
firesim launchrunfarm
firesim launchrunfarm
In this case, since we are already running the machine with the FPGA (``localhost``),
this command should not launch any machine and should be quick.
@ -159,7 +157,14 @@ You should expect output like the following:
::
TBD
$ firesim launchrunfarm
FireSim Manager. Docs: https://docs.fires.im
Running: launchrunfarm
firesim_rocket_singlecore_no_nic is overriding a deploy triplet in your config_hwdb.yaml file. Make sure you understand why!
WARNING: Skipping launchrunfarm since run hosts are externally provisioned.
The full log of this run is:
.../firesim/deploy/logs/2023-03-06--00-20-37-launchrunfarm-24T0KOGRHBMSHAV5.log
Setting up the simulation infrastructure
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@ -171,14 +176,24 @@ let's run:
::
firesim infrasetup
firesim infrasetup
For a complete run, you should expect output like the following:
::
TBD
$ firesim infrasetup FireSim Manager. Docs: https://docs.fires.im
Running: infrasetup
firesim_rocket_singlecore_no_nic is overriding a deploy triplet in your config_hwdb.yaml file. Make sure you understand why!
Building FPGA software driver for FireSim-FireSimRocketConfig-BaseVitisConfig
...
[localhost] Checking if host instance is up...
[localhost] Copying FPGA simulation infrastructure for slot: 0.
[localhost] Clearing all FPGA Slots.
The full log of this run is:
.../firesim/deploy/logs/2023-03-06--01-22-46-infrasetup-35ZP4WUOX8KUYBF3.log
Many of these tasks will take several minutes, especially on a clean copy of
the repo. The console output here contains the "user-friendly" version of the
@ -205,7 +220,14 @@ nodes every 10s. When you do this, you will initially see output like:
::
TBD
$ firesim runworkload
FireSim Manager. Docs: https://docs.fires.im
Running: runworkload
firesim_rocket_singlecore_no_nic is overriding a deploy triplet in your config_hwdb.yaml file. Make sure you understand why!
Creating the directory: .../firesim/deploy/results-workload/2023-03-06--01-25-34-linux-uniform/
[localhost] Checking if host instance is up...
[localhost] Starting FPGA simulation for slot: 0.
If you don't look quickly, you might miss it, since it will get replaced with a
live status page:
@ -383,7 +405,14 @@ Which should present you with the following:
::
TBD
$ firesim terminaterunfarm
FireSim Manager. Docs: https://docs.fires.im
Running: terminaterunfarm
firesim_rocket_singlecore_no_nic is overriding a deploy triplet in your config_hwdb.yaml file. Make sure you understand why!
WARNING: Skipping terminaterunfarm since run hosts are externally provisioned.
The full log of this run is:
.../firesim/deploy/logs/2023-03-06--01-34-45-terminaterunfarm-YFXAJCRGF8KF4LQ3.log
Since we are re-using an existing machine that is already booted, this command should do nothing and be quick.

View File

@ -34,7 +34,7 @@ $(vitis): export CXXFLAGS := $(CXXFLAGS) $(common_cxx_flags) $(DRIVER_CXXOPTS) \
-idirafter ${CONDA_PREFIX}/include -idirafter /usr/include -idirafter $(XILINX_XRT)/include
# -ldl needed for Ubuntu 20.04 systems (is backwards compatible with U18.04 systems)
$(vitis): export LDFLAGS := $(LDFLAGS) $(common_ld_flags) -Wl,-rpath='$$$$ORIGIN' \
-L${CONDA_PREFIX}/lib -Wl,-rpath-link=/usr/lib/x86_64-linux-gnu -L$(XILINX_XRT)/lib -luuid -lxrt_coreutil -ldl
-L${CONDA_PREFIX}/lib -Wl,-rpath-link=/usr/lib/x86_64-linux-gnu -L/usr/lib/x86_64-linux-gnu -L$(XILINX_XRT)/lib -luuid -lxrt_coreutil -ldl
# Compile Driver