masahi commented on PR #15118:
URL: https://github.com/apache/tvm/pull/15118#issuecomment-1596615802

   This assumes that all entry functions get the same workspace size right?
   
   I also have a WIP branch 
https://github.com/masahi/tvm/tree/workspace-provider-entry-func that 
calculates the minimum-necessary workspace size for each function that calls 
another functions with `kWorkSpaceSize` attribute. It doesn't yet handle the 
case where the same function with `kWorkSpaceSize` is called by multiple entry 
functions, with different maximum workspace sizes. Since we modify the function 
signature for a function that needs workspace param, the param size needs to 
take into account all entry funcs that call it.    
   
   So the upshot is, even though different entry funcs can have its own minimum 
workspace size, to handle the case above we need to take the max over all 
functions with `kWorkSpaceSize`, even though a single entry func might not call 
all of them. I was planning to add such logic on top of my branch, but looking 
at this PR makes me realize that this simple patch is effectively sufficient.
   
   Do you agree with my assessment? @yelite  


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to