cutlass icon indicating copy to clipboard operation
cutlass copied to clipboard

[FEA][torchinductor-EVT] Allow function source code to be passed directly to EVT tracer

Open mlazos opened this issue 8 months ago • 3 comments

Is your feature request related to a problem? Please describe. At https://github.com/NVIDIA/cutlass/blob/5e497243f7ad13a2aa842143f9b10bbb23d98292/python/cutlass/epilogue/epilogue.py#L117

the trace(..) API takes in a function. The main issue here is that when dynamically defining a python function like so

fn = exec("""
def fn(x):
  return x
"""

extracting the source using inspect.getsource here fails.

This is how inductor generates the python source in essence (it generates a function string) so this does signature doesn't work.

Describe the solution you'd like Modify the signature of trace to take the function source string directly.

cc @henrylhtsang, @eellison

mlazos avatar Apr 17 '25 05:04 mlazos

@jackkosaian

hwu36 avatar Apr 30 '25 02:04 hwu36

@apuaachen, can you help take a look at this EVT request?

jackkosaian avatar Apr 30 '25 11:04 jackkosaian

This issue has been labeled inactive-30d due to no recent activity in the past 30 days. Please close this issue if no further response or action is needed. Otherwise, please respond with a comment indicating any updates or changes to the original issue and/or confirm this issue still needs to be addressed. This issue will be labeled inactive-90d if there is no activity in the next 60 days.

github-actions[bot] avatar May 30 '25 12:05 github-actions[bot]

This issue has been labeled inactive-90d due to no recent activity in the past 90 days. Please close this issue if no further response or action is needed. Otherwise, please respond with a comment indicating any updates or changes to the original issue and/or confirm this issue still needs to be addressed.

github-actions[bot] avatar Aug 28 '25 12:08 github-actions[bot]