mirror of
https://github.com/RRZE-HPC/OSACA.git
synced 2025-12-16 00:50:06 +01:00
- Enhanced RISC-V parser to support reloc_type and symbol in ImmediateOperand. - Added missing attributes (reloc_type, symbol) to ImmediateOperand and updated __eq__ for backward compatibility. - Fixed all flake8 (E501, E265, F401, F841) and Black formatting issues across the codebase. - Improved docstrings and split long lines for better readability. - Fixed test failures related to ImmediateOperand instantiation and attribute errors. - Ensured all tests pass, including edge cases for RISC-V, x86, and AArch64. - Updated .gitignore and documentation as needed. - Renamed example files for consistency (rv6 -> rv64).
35 lines
847 B
Python
Executable File
35 lines
847 B
Python
Executable File
#!/usr/bin/env python3
|
|
from glob import glob
|
|
import os.path
|
|
import sys
|
|
|
|
sys.path[0:0] = ["../.."]
|
|
|
|
failed = False
|
|
try:
|
|
from osaca.semantics.hw_model import MachineModel
|
|
except ModuleNotFoundError:
|
|
print(
|
|
"Unable to import MachineModel, probably some dependency is not yet "
|
|
"installed. SKIPPING. First run of OSACA may take a while to build "
|
|
"caches, subsequent runs will be as fast as ever."
|
|
)
|
|
sys.exit()
|
|
|
|
print("Building cache: ", end="")
|
|
sys.stdout.flush()
|
|
|
|
# Iterating architectures
|
|
for f in glob(os.path.join(os.path.dirname(__file__), "*.yml")):
|
|
MachineModel(path_to_yaml=f)
|
|
print(".", end="")
|
|
sys.stdout.flush()
|
|
|
|
# Iterating ISAs
|
|
for f in glob(os.path.join(os.path.dirname(__file__), "isa/*.yml")):
|
|
MachineModel(path_to_yaml=f)
|
|
print("+", end="")
|
|
sys.stdout.flush()
|
|
|
|
print()
|