Enforce Hermeticity in Vortex Build Process
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 25/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Bastante claro
- Estado de actividad
- Tranquilo
- Área
- build-system, tooling
Línea de trabajo
Start by reading the Bazel hermeticity documentation linked in the issue and inspect the existing CI scripts, container setup, build scripts, and Makefiles mentioned in the proposal. The first iteration should cover local build and development, with CI held to the same requirements; FPGA deployment is explicitly out of scope. Done means Bazel provides a single entry point for build and test and enforces declared, reproducible dependencies.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Proposal
Vortex project depends on a complex toolchain and gets deployed in a variety of environments (local development, server development, FPGA deployment, CI pipeline, workshop tutorial, containerized, non-conatinerized, etc).
Furthermore, incorporating vortex into other simulation environments can introduce unknown requirements down the road.
AI tools are good enough to resolve these issues in a local context, but have no support for global correctness. Its better to be more explicit about the build requirements, beyond just readme, build scripts, make files.
The Bazel build system introduces the concept of hermeticity in build systems: https://bazel.build/basics/hermeticity
Emphasis on this section of the documentation:
The two important aspects of hermeticity are:
Isolation: Hermetic build systems treat tools as source code. They download copies of tools and manage their storage and use inside managed file trees. This creates isolation between the host machine and local user, including installed versions of languages.
Source identity: Hermetic build systems try to ensure the sameness of inputs. Code repositories, such as Git, identify sets of code mutations with a unique hash code. Hermetic build systems use this hash to identify changes to the build’s input.
Scope and Discussion
This is a relatively large undertaking, but I expect it to scale well into the future with much less "emergency failures" occurring. Prior vortex infra work such as ci, containerization, docs, build scripts, fpga deploy which I have worked on should all be encapsulated by this project. Another benefit of this approach is that the rules are explicitly writen in configuration files so future authors can add, modify, debug, etc without deep rearchitecting. It may increase local repo size since all deps will be kept locally. There might be a method to do a shared cloud env (ie for fpga licenses, NFS, etc). I'm sure this can be tackled in future commits. As such, this first iteration will focus on local build and development. I expect CI to have the same requirements. More specifically, FPGA is not included in the first iteration.
Motivation
Currently vortex has a container, which helps you distribute a standard environment. However, there no automatic method to check when a new dependency is required, but not added to the container. This is because some users may elect not to use the container in the first place!! In other words, the container is only useful if it cannot be side stepped. One goal of this work is to enforce one entry point to build, test, run, etc vortex. This will be a large undertaking, but Bazel is capable of handling all of the hard work, as long as its configured correctly and tested thoroughly. Another goal of this work is to detect when deps are out of date or changed, this is as simple checking their hash before proceeding with compilation or hitting cache. Finally, Bazel encourages good repo structure, teaches good habits, and introduces a topical and highly requested skill for systems developers should be familiar with. Bazel can also automatically parallelize and cache builds to improve performance without compromising fragmented binaries (consider: if you rerun a executable without recompiling latest changes). Finally, you can easily generate shareable binaries. This is particularly relevant to the vortex project for a number of reasons: 1) Distribute executables across multiple nodes to run large scale sims. 2) Compile vortex on a performance node, then just send executable to FPGA node for faster iteration cycles. 3) Data collection on multiple configs or some auto tuning framework
Implementation
I plan to try migrating to Bazel since it exposes all the tools that I need, as well as a familiar command line interface: bazel build ..., bazel test ... to wrap existing ci scripts. Using Bazel strictly enforces the rules of hermetic builds mentioned above. Furthermore it prevents side-stepping these rules with quick convenience scripts (.sh). You can still pass envs and flags to match the expected vortex configs format.
- Lenguaje dominante
- Verilog
- Estrellas
- 2.4k
- Forks
- 563
- Merge medio
- 2 d 12 h
- PR fusionados (30 d)
- 33
Preparar el entorno
Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de vortexgpgpu/vortex
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
vortexgpgpu/vortex#501 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
vortexgpgpu/vortex#499 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 4/5 3-5 días Aptitud para principiantes 22/100
vortexgpgpu/vortex#505 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 4/5 3-5 días Aptitud para principiantes 28/100
vortexgpgpu/vortex#504 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 22/100
vortexgpgpu/vortex#503 ·
Los mantenedores suelen responder en 1 día
Todos los issues de vortexgpgpu/vortex
Issues similares
-
Update bundled `node` dependencyAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
layer5io/blowhorn-site#781 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
Los mantenedores suelen responder en 1 día
-
Build support: NativeScriptAbiertogood first issue
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100