aws / aws-fpga
Source Code Overview

Analysis scope, overview of main, test, generated, deployment, build, and other code.

Source Code Analysis Scope
Files includes and excluded from analyses
vh
sv
v
tcl
vhd
txt
veo
f
vho
patch
svh
vhdl
diff
cl
ui
cfg
ini
gitmodules
  • 30 extensions are included in analyses: vh, sv, v, tcl, vhd, md, xml, txt, h, c, sh, py, inc, veo, f, gitignore, cpp, vho, patch, svh, vhdl, diff, cl, ui, json, cfg, ini, css, gitmodules, hpp
  • 8 criteria are used to exclude files from analysis:
    • exclude files with path like ".*/docs/.*" (Documentation) (52 files).
    • exclude files with path like ".*/[.][a-zA-Z0-9_]+.*" (Hidden files and folders) (23 files).
    • exclude files with path like ".*/git[-]history[.]txt" (Git history) (1 file).
    • exclude files with path like ".*/git[-][a-zA-Z0-9_]+[.]txt" (Git data exports for sokrates analyses) (0 files).
    • exclude files with path like ".*/bin/.*" (Binaries for distribution) (17 files).
    • exclude files with path like ".*/(3rd|[Tt]hird)[-_]?[Pp]arty/.*" (Dependencies) (12 files).
    • exclude files with path like ".*[.]txt" (Text files) (68 files).
    • exclude files with path like ".*/sokrates_conventions[.]json" (Sokrates scoping conventions) (1 file).
Overview of Analyzed Files
Basic stats on analyzed files
Intro
For analysis purposes we separate files in scope into several categories: main, test, generated, deployment and build, and other.

  • The main category contains all manually created source code files that are being used in the production.
  • Files in the main category are used as input for other analyses: logical decomposition, concerns, duplication, file size, unit size, and conditional complexity.
  • Test source code files are used only for testing of the product. These files are normally not deployed to production.
  • Build and deployment source code files are used to configure or support build and deployment process.
  • Generated source code files are automatically generated files that have not been manually changed after generation.
  • While a source code folder may contain a number of files, we are primarily interested in the source code files that are being written and maintained by developers.
  • Files containing binaries, documentation, or third-party libraries, for instance, are excluded from analysis. The exception are third-party libraries that have been changed by developers.

main4881418 LOC (55%) 1176 files
test4915 LOC (<1%) 51 files
generated0 LOC (0%) 0 files
build and deployment3459 LOC (<1%) 28 files
other3911436 LOC (44%) 622 files
Main Code
All manually created or maintained source code that defines logic of the product that is run in a production environment.
vhd
v
sv
vh
tcl
vho
veo
svh
f
ui
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*".
  • 1176 files match defined criteria (4,881,418 lines of code, 100.0% vs. main code):
    • 116 *.vhd files (4,330,970 lines of code)
    • 215 *.v files (283,666 lines of code)
    • 256 *.sv files (145,158 lines of code)
    • 214 *.vh files (73,314 lines of code)
    • 178 *.tcl files (17,866 lines of code)
    • 33 *.c files (10,359 lines of code)
    • 51 *.h files (5,575 lines of code)
    • 16 *.py files (3,145 lines of code)
    • 16 *.vho files (2,980 lines of code)
    • 10 *.cpp files (2,825 lines of code)
    • 22 *.veo files (2,376 lines of code)
    • 8 *.svh files (1,494 lines of code)
    • 31 *.inc files (1,124 lines of code)
    • 8 *.f files (516 lines of code)
    • 2 *.ui files (50 lines of code)
  • " *.vhd" is biggest, containing 88.72% of code.
  • " *.ui" is smallest, containing 0% of code.


*.vhd4330970 LOC (88%) 116 files
*.v283666 LOC (5%) 215 files
*.sv145158 LOC (2%) 256 files
*.vh73314 LOC (1%) 214 files
*.tcl17866 LOC (<1%) 178 files
*.c10359 LOC (<1%) 33 files
*.h5575 LOC (<1%) 51 files
*.py3145 LOC (<1%) 16 files
*.vho2980 LOC (<1%) 16 files
*.cpp2825 LOC (<1%) 10 files
*.veo2376 LOC (<1%) 22 files
*.svh1494 LOC (<1%) 8 files
*.inc1124 LOC (<1%) 31 files
*.f516 LOC (<1%) 8 files
*.ui50 LOC (<1%) 2 files
Test Code
Used only for testing of the product. Normally not deployed in a production environment.
tcl
sv
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*/[Tt]ests/.*".
    • files with paths like ".*/test_.*".
    • files with paths like ".*_tests[.].*".
    • files with paths like ".*_test[.].*".
    • files with any line of content like ".*/simpletest/.*".
  • 51 files match defined criteria (4,915 lines of code, 0.1% vs. main code):
    • 28 *.py files (2,584 lines of code)
    • 9 *.c files (1,140 lines of code)
    • 2 *.tcl files (486 lines of code)
    • 8 *.sv files (472 lines of code)
    • 3 *.sh files (228 lines of code)
    • 1 *.h files (5 lines of code)
  • " *.py" is biggest, containing 52.57% of code.
  • " *.h" is smallest, containing 0.1% of code.


*.py2584 LOC (52%) 28 files
*.c1140 LOC (23%) 9 files
*.tcl486 LOC (9%) 2 files
*.sv472 LOC (9%) 8 files
*.sh228 LOC (4%) 3 files
*.h5 LOC (<1%) 1 files
Build and Deployment Code
Source code used to configure or support build and deployment process.
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]sh".
    • files with paths like ".*[.]git[a-z]+".
    • files with paths like ".*/[.]gitmodules".
    • files with paths like ".*/[.]gitignore".
  • 28 files match defined criteria (3,459 lines of code, 0.1% vs. main code). All matches are in *.sh files.


*.sh3459 LOC (100%) 28 files
Other Code
vhd
v
vh
sv
patch
tcl
f
veo
cl
svh
ini
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]md".
    • files with paths like ".*/README[.][a-z0-9]+".
    • files with paths like ".*[.]txt".
    • files with paths like ".*/[Ee]xamples/.*".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*[.]patch".
    • files with paths like ".*/LICENSE[.][a-z0-9]+".
    • files with paths like ".*[.]json".
    • files with paths like ".*[.]diff".
    • files with paths like ".*[.]ini".
    • files with paths like ".*[.](xml|xsd|robot|sql|pgsql|dashboard|profile|ipynb|raml|avsc|al)".
  • 622 files match defined criteria (3,911,436 lines of code, 80.1% vs. main code):
    • 20 *.vhd files (2,023,779 lines of code)
    • 97 *.xml files (1,602,466 lines of code)
    • 47 *.v files (163,818 lines of code)
    • 200 *.vh files (74,294 lines of code)
    • 87 *.sv files (25,836 lines of code)
    • 59 *.md files (5,943 lines of code)
    • 11 *.patch files (5,478 lines of code)
    • 29 *.tcl files (2,972 lines of code)
    • 11 *.sh files (1,759 lines of code)
    • 14 *.c files (1,454 lines of code)
    • 22 *.f files (1,444 lines of code)
    • 9 *.veo files (844 lines of code)
    • 1 *.inc files (617 lines of code)
    • 2 *.cpp files (334 lines of code)
    • 6 *.h files (159 lines of code)
    • 3 *.cl files (135 lines of code)
    • 1 *.svh files (59 lines of code)
    • 1 *.json files (41 lines of code)
    • 2 *.ini files (4 lines of code)
  • " *.vhd" is biggest, containing 51.74% of code.
  • " *.ini" is smallest, containing 0% of code.


*.vhd2023779 LOC (51%) 20 files
*.xml1602466 LOC (40%) 97 files
*.v163818 LOC (4%) 47 files
*.vh74294 LOC (1%) 200 files
*.sv25836 LOC (<1%) 87 files
*.md5943 LOC (<1%) 59 files
*.patch5478 LOC (<1%) 11 files
*.tcl2972 LOC (<1%) 29 files
*.sh1759 LOC (<1%) 11 files
*.c1454 LOC (<1%) 14 files
*.f1444 LOC (<1%) 22 files
*.veo844 LOC (<1%) 9 files
*.inc617 LOC (<1%) 1 files
*.cpp334 LOC (<1%) 2 files
*.h159 LOC (<1%) 6 files
*.cl135 LOC (<1%) 3 files
*.svh59 LOC (<1%) 1 files
*.json41 LOC (<1%) 1 files
*.ini4 LOC (<1%) 2 files
Analyzers
Info about analyzers used for source code examinations.
  • *.vhd files are analyzed with DefaultLanguageAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Basic code cleaning (empty lines removed for LOC calculations and duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.v files are analyzed with GoLangAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • Basic heuristic dependency analysis
  • *.sv files are analyzed with DefaultLanguageAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Basic code cleaning (empty lines removed for LOC calculations and duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.vh files are analyzed with DefaultLanguageAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Basic code cleaning (empty lines removed for LOC calculations and duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.tcl files are analyzed with DefaultLanguageAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Basic code cleaning (empty lines removed for LOC calculations and duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.c files are analyzed with CStyleAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • No dependency analysis
  • *.h files are analyzed with CppAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • Advanced heuristic dependency analysis
  • *.py files are analyzed with PythonAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • Basic heuristic dependency analysis
  • *.vho files are analyzed with DefaultLanguageAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Basic code cleaning (empty lines removed for LOC calculations and duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.cpp files are analyzed with CppAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • Advanced heuristic dependency analysis
  • *.veo files are analyzed with DefaultLanguageAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Basic code cleaning (empty lines removed for LOC calculations and duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.svh files are analyzed with DefaultLanguageAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Basic code cleaning (empty lines removed for LOC calculations and duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.inc files are analyzed with PhpAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • Basic heuristic dependency analysis
  • *.f files are analyzed with DefaultLanguageAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Basic code cleaning (empty lines removed for LOC calculations and duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.ui files are analyzed with XmlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis


2022-01-31 07:17