-
Notifications
You must be signed in to change notification settings - Fork 331
[Debug] Introduce T.print for buffer and variables logging on frontend
#45
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
Conversation
…n, revise project name, and change theme to Furo
… kernel interface
T.print to help us print buffer and variables on frontendT.print to help print buffer and variables on frontend
T.print to help print buffer and variables on frontendT.print for buffer and variables logging on frontend
|
|
We should also need to implement test case for register files.
It's not simple for us to print fragment data. |
This pull request introduces a new debugging feature for CUDA code generation and includes several related changes across multiple files. The most important changes include the addition of a new header file for debugging, the implementation of device-side debug printing templates, and the creation of tests for these new debugging features.
Debugging Feature Implementation:
src/target/codegen_cuda.cc: Added an include statement for the newdebug.hheader file.src/tl_templates/cuda/debug.h: Implemented template functions for device-side debug printing, including specializations for various data types such asint,float,half,half_t,bfloat16_t, anddouble.Testing:
testing/python/debug/test_tilelang_debug_print.py: Added tests for the new debug printing functionalities, including tests for printing buffer values and conditional printing.Language Enhancements:
tilelang/language/__init__.py: Updated imports to include the newprintfunction andget_thread_bindingutility. [1] [2]tilelang/language/kernel.py: Added new methodsget_thread_bindingandget_thread_bindingsto retrieve thread bindings for different dimensions. [1] [2]Utility Functions:
tilelang/language/print.py: Created a new module for debug printing macros and utilities, including functions for printing variables, buffers, and conditionally executing debug prints.