Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-05-09 Thread via GitHub
masahi merged PR #16955: URL: https://github.com/apache/tvm/pull/16955 -- 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: commits-unsubscr...@tvm.apache.or

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-05-08 Thread via GitHub
masahi commented on PR #16955: URL: https://github.com/apache/tvm/pull/16955#issuecomment-2101267069 @tvm-bot rerun -- 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 unsub

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-05-08 Thread via GitHub
Lunderberg commented on code in PR #16955: URL: https://github.com/apache/tvm/pull/16955#discussion_r1594281102 ## python/tvm/script/parser/relax/entry.py: ## @@ -296,13 +298,17 @@ class CallableProxy(StructInfoProxy): purity : bool Whether the callable is pure.

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-05-08 Thread via GitHub
Lunderberg commented on code in PR #16955: URL: https://github.com/apache/tvm/pull/16955#discussion_r1594267879 ## python/tvm/relax/op/memory/view.py: ## @@ -0,0 +1,77 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. Se

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-05-03 Thread via GitHub
masahi commented on code in PR #16955: URL: https://github.com/apache/tvm/pull/16955#discussion_r1589667378 ## python/tvm/script/parser/relax/entry.py: ## @@ -296,13 +298,17 @@ class CallableProxy(StructInfoProxy): purity : bool Whether the callable is pure. +

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-05-02 Thread via GitHub
Lunderberg commented on PR #16955: URL: https://github.com/apache/tvm/pull/16955#issuecomment-2091928478 Sounds good, and thank you on the feedback! -- 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 t

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-05-02 Thread via GitHub
tqchen commented on PR #16955: URL: https://github.com/apache/tvm/pull/16955#issuecomment-2091267123 Thank you! my previous comments are addressed. Unfortunately i didn't get a chance to do a thourough read, would be good to get review from another person. So i just dissmissed my previous

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-05-02 Thread via GitHub
Lunderberg commented on PR #16955: URL: https://github.com/apache/tvm/pull/16955#issuecomment-2091168524 Having `R.memory.ensure_aligned` makes sense, as that will allow us to explicitly mark where additional copies are required after applying `R.memory.view`, before passing to a compute ke

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-04-30 Thread via GitHub
tqchen commented on PR #16955: URL: https://github.com/apache/tvm/pull/16955#issuecomment-2087792055 `R.memory.ensure_compact` will actually return a new NDArray whose `elem_offset=0`, and for devices that allows explicit ptr moving, this is something that can accelerate backends -- This

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-04-30 Thread via GitHub
Lunderberg commented on PR #16955: URL: https://github.com/apache/tvm/pull/16955#issuecomment-2087130666 Changes have been made as requested, ready for re-review. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-04-30 Thread via GitHub
Lunderberg commented on code in PR #16955: URL: https://github.com/apache/tvm/pull/16955#discussion_r1585490595 ## src/relax/op/tensor/view.h: ## @@ -0,0 +1,38 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-04-30 Thread via GitHub
Lunderberg commented on PR #16955: URL: https://github.com/apache/tvm/pull/16955#issuecomment-2087070331 > Having view operation can in general cause problems mainly because most ops(including generated and external ones) assumes `elem_offset = 0` So long as the operations assert that

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-04-30 Thread via GitHub
tqchen commented on code in PR #16955: URL: https://github.com/apache/tvm/pull/16955#discussion_r1584898774 ## src/relax/op/tensor/view.h: ## @@ -0,0 +1,38 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-04-30 Thread via GitHub
tqchen commented on PR #16955: URL: https://github.com/apache/tvm/pull/16955#issuecomment-2085436158 Just want to note here. Having view operation can in general cause problems mainly because most ops(including generated and external ones) assumes `elem_offset = 0` for performance reasons(

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-04-29 Thread via GitHub
Lunderberg commented on code in PR #16955: URL: https://github.com/apache/tvm/pull/16955#discussion_r1583602159 ## src/relax/op/tensor/view.cc: ## @@ -0,0 +1,359 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. Se

Re: [PR] [Relax] Implement relax.op.view [tvm]

2024-04-29 Thread via GitHub
masahi commented on code in PR #16955: URL: https://github.com/apache/tvm/pull/16955#discussion_r1583565962 ## src/relax/op/tensor/view.cc: ## @@ -0,0 +1,359 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See th