Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
LG, one nit.
libc/utils/gpu/loader/Main.cpp | ||
---|---|---|
40 | move this first, then emit an error if the file was not opened. |
libc/utils/gpu/loader/Main.cpp | ||
---|---|---|
34 | Nit: Can we use strtoul instead? Sometimes it's convenient to be able to use hex numbers and you would also get an indication if the input is not a number. | |
libc/utils/gpu/loader/nvptx/Loader.cpp | ||
135–139 | If we're allowing controlling the number of blocks/threads at all, is there a reason not to allow specifying all dimensions? |
libc/utils/gpu/loader/Main.cpp | ||
---|---|---|
34 | Good point, just used to using the quick-and-dirty atoi. | |
libc/utils/gpu/loader/nvptx/Loader.cpp | ||
135–139 | I wasn't sure if I should bother, but I could definitely add it since it's hardly anymore work from what's here. I think internally for implementations we'll need to generate all of our thread id's using the full dimensions as well, but that's probably standard. |
libc/utils/gpu/loader/nvptx/Loader.cpp | ||
---|---|---|
135–139 | That's one common pattern. However, there are also use cases when small kernels benefit performance-wise from being able to use x/y/z indices directly, without having to calculate the single thread ID and then split it into sub-indices. There's also a limit on how large the individual dimensions can be, so specifying a single one may not be sufficient for large inputs: |
Not sure if we'll have a use for dynamic shared memory in libc so far. Might be worthwhile for testing though, since this is a generic launcher of kernels.
Nit: Can we use strtoul instead? Sometimes it's convenient to be able to use hex numbers and you would also get an indication if the input is not a number.