Skip to content

Latest commit

 

History

History
81 lines (44 loc) · 4.83 KB

README.MD

File metadata and controls

81 lines (44 loc) · 4.83 KB

Dependencies:

Nodejs. webpack

Steps to set up the development environment:

  1. Download NodeJs (v10.19.0)
  2. Install libraries: Go to the web-app directory and run "npm install". The required versions can be found in package.json file.
  3. Install Webpack: In the same directory as step 3, run "sudo npm install -g webpack".
  4. Configurate the LLFI root path for the server:
    The program uses the environment variable $llfibuild as the path of the llfi build directory.
    You can set the environment variable $llfibuild in your system to point it to the LLFI build directory in your local machine.

Start the server: Go to the /web-app/server folder and run "node server.js"

Start the front-end dev tool: Go to the web-app directory and run "webpack" or "webpack -w"

Overview of the Web Application

Reference: LLFI Web GUI

The procedure for performing fault injections in LLTFI and view results using the Web GUI is described below.

Fault Injection Procedure using the GUI

The first step is to select the target program for fault injection. The user can upload any standalone C/C++ source file by selecting; File->Open File.

The figure below is a screenshot for opening a single file.

Alt text

Once the file is uploaded:

  1. Compile To IR: After a C/C++ source file is uploaded, click on the "Compile To IR" button. When the program is successfully compiled, a success message with the name of IR file that is created will be displayed. The figure below is a screenshot of the successful completion of the "Compile To IR" step.

Alt text

  1. Instrument: Once the intermediate representation (IR) file is created, click on the "Instrument" button. The instrument dialog box will open, where the user can select the configuration parameters (input.yaml).

For Hardware Faults Injection, select "Hardware Injection", then select the Instruction Type, Register Location and trace options and then click the "Instrument" button in the dialog box. The figure below is an example of the Hardware Faults Instrument interface.

Alt text

  1. Profiling: After instrumentation, click on the "Profiling" button. If the program requires any command line inputs, provide them in the "Command Line Input" text box before clicking "Profiling".

The figure below is the successful completion of hardware fault profiling.

Alt text

  1. Runtime Options: Click on the "Runtime Options" button to configure the fault injection. The user can also save the profile by checking the "Save Profile" checkbox before clicking "Submit". Click on the "Delete Run" button to delete a runtime option.

For Hardware Fault Injection, the user should provide the 'Number of Runs' and 'Fault injection type' (mandatory), while other inputs are optional. The figure below is a screenshot of the Hardware Runtime Options interface.

Alt text

  1. Fault Injection: Click on the "Inject Fault" button to perform fault injection. When fault injection is completed click on the "Fault Injection Status" and "Fault Summary" tabs to view the result of the fault injections.

The figure below is a screenshot of the completion of a Hardware "Inject Fault", you can also see the "Fault Injection Status" table in the figure.

Alt text Alt text

  1. Trace Graph: Select one or more traces from the "Fault Injection Status" tabs. Click on the "Trace Graph" button and a trace graph window will pop up. The trace graph contains the flow of the LLVM IR instructions, and the mapping information of LLVM IR instructions to the C source code (if applicable).

Alt text

SDC Option: By default, the SDC's are reported by making a diff between the std_outputfile and the golden_output. The user can customize the way SDC is generated by writing a script and providing the path of the script to the environment variable COMPARE.