Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarify Make targets? #7

Open
sampsyo opened this issue Feb 10, 2020 · 1 comment
Open

Clarify Make targets? #7

sampsyo opened this issue Feb 10, 2020 · 1 comment

Comments

@sampsyo
Copy link
Collaborator

sampsyo commented Feb 10, 2020

The README currently says to run make cosim to run an example. But currently, it doesn't look like cosim is a valid target.

More broadly, for using this stuff as an example for other people trying to write CUDA-Lite code, it would be nice to know what targets are available—it looks like there are several with different intents and different origins:

  • analysis: Defined in some example-specific Makefiles to run multiple versions. (The concept of "versions" might also need additional explanation—it looks like the idea for all of these examples is to possibly have multiple drop-in alternative implementations of the same kernel. That's fine for full-fledged performance tests, but it's a little confusing if you're just trying to get one thing up and running from scratch. Maybe it would make sense to have one example without "versions" for simplicity?)
  • stats: Actually not entirely sure what this does? (And default is an alias for stats?)
  • kernel/<version>/kernel.riscv: Build the device-side code for a given kernel version.
  • *.cosim (where * is the name of the example, i.e., $HOST_TARGET): Build the host-side program.
  • <version> or kernel/<version>/*.cosim.log (where the latter is $HOST_TARGET again): Actually run the simulation?

In general, it would be awesome to have documented the expected targets do these things separately:

  • Build the host code (for simulation).
  • Build the device code.
  • Run the simulation.
  • Plot the statistics into a cool graph.

…because it's often super convenient to do those individually rather than in one fell swoop. (And I don't think they need fancy .PHONY target names! Just knowing what does what can really help orient new users.)

@drichmond
Copy link
Collaborator

I think this is fixed now?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants