Commit b832361
Migrates Tripy to use the tensorrt dialect instead of StableHLO (#607)
Migrates Tripy to use the `tensorrt` dialect instead of StableHLO. The
latter is a lower level representation that the TensorRT network API,
meaning that we first break down high level Tripy operations and then
pattern match them back up. Using the `tensorrt` dialect allows us to go
directly to TensorRT without so many intervening layers of translation,
which reduces complexity and bugs, and improves performance.
Broadly, this change does the following:
- Removes FlatIR
- Make Trace responsible for mapping to MLIR
- Trace operations represent MLIR operations 1:1
- Makes the frontend API responsible for composing Trace operations
---------
Signed-off-by: yizhuoz004 <yizhuoz@nvidia.com>
Co-authored-by: Jhalak Patel <jhalakp@nvidia.com>
Co-authored-by: Yizhuo Zhang <yizhuoz@nvidia.com>1 parent 6a9cfa9 commit b832361
File tree
353 files changed
+8030
-11910
lines changed- tripy
- docs
- post0_developer_guides
- pre0_user_guides
- examples
- nanogpt
- segment-anything-model-v2
- sam2
- modeling
- backbones
- sam
- utils
- notebooks
- nvtripy
- backend
- api
- mlir
- common
- flat_ir
- ops
- frontend
- module
- conv
- ops
- binary
- pooling
- reduce
- unary
- logging
- trace
- ops
- utils
- tests
- backend
- api
- mlir
- common
- flat_ir
- ops
- frontend
- module
- ops
- integration
- logging
- performance
- cases
- tools
- trace
- ops
- utils
- json
- wrappers
- wrappers
- tools
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
353 files changed
+8030
-11910
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
88 | 88 | | |
89 | 89 | | |
90 | 90 | | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
70 | 70 | | |
71 | 71 | | |
72 | 72 | | |
| 73 | + | |
73 | 74 | | |
74 | 75 | | |
75 | 76 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
45 | 45 | | |
46 | 46 | | |
47 | 47 | | |
48 | | - | |
| 48 | + | |
49 | 49 | | |
50 | 50 | | |
51 | 51 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
101 | 101 | | |
102 | 102 | | |
103 | 103 | | |
104 | | - | |
| 104 | + | |
105 | 105 | | |
106 | 106 | | |
107 | 107 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
30 | | - | |
31 | | - | |
32 | 30 | | |
33 | 31 | | |
34 | 32 | | |
| |||
179 | 177 | | |
180 | 178 | | |
181 | 179 | | |
182 | | - | |
| 180 | + | |
183 | 181 | | |
184 | 182 | | |
185 | | - | |
| 183 | + | |
186 | 184 | | |
187 | 185 | | |
188 | 186 | | |
| |||
206 | 204 | | |
207 | 205 | | |
208 | 206 | | |
209 | | - | |
210 | | - | |
211 | | - | |
212 | | - | |
213 | | - | |
214 | | - | |
215 | | - | |
216 | | - | |
217 | | - | |
218 | | - | |
219 | | - | |
220 | | - | |
221 | | - | |
222 | | - | |
223 | | - | |
224 | | - | |
225 | | - | |
226 | | - | |
227 | | - | |
228 | | - | |
229 | | - | |
230 | | - | |
231 | | - | |
232 | | - | |
233 | | - | |
234 | | - | |
235 | | - | |
236 | | - | |
237 | | - | |
238 | | - | |
239 | | - | |
240 | | - | |
241 | | - | |
242 | | - | |
243 | | - | |
244 | | - | |
245 | | - | |
246 | | - | |
247 | | - | |
248 | | - | |
249 | | - | |
250 | | - | |
251 | | - | |
252 | | - | |
253 | | - | |
254 | | - | |
255 | | - | |
256 | | - | |
257 | | - | |
258 | | - | |
259 | | - | |
260 | | - | |
261 | | - | |
262 | | - | |
263 | | - | |
264 | | - | |
265 | | - | |
266 | 207 | | |
267 | 208 | | |
268 | 209 | | |
269 | | - | |
| 210 | + | |
270 | 211 | | |
271 | | - | |
| 212 | + | |
272 | 213 | | |
273 | 214 | | |
274 | 215 | | |
| |||
336 | 277 | | |
337 | 278 | | |
338 | 279 | | |
339 | | - | |
| 280 | + | |
| 281 | + | |
340 | 282 | | |
341 | 283 | | |
342 | 284 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
22 | | - | |
23 | 22 | | |
24 | 23 | | |
25 | 24 | | |
26 | 25 | | |
27 | 26 | | |
28 | 27 | | |
29 | 28 | | |
30 | | - | |
31 | 29 | | |
| 30 | + | |
32 | 31 | | |
33 | 32 | | |
34 | 33 | | |
| |||
93 | 92 | | |
94 | 93 | | |
95 | 94 | | |
96 | | - | |
| 95 | + | |
97 | 96 | | |
98 | 97 | | |
99 | 98 | | |
| |||
181 | 180 | | |
182 | 181 | | |
183 | 182 | | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
184 | 197 | | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
185 | 201 | | |
186 | 202 | | |
187 | 203 | | |
| |||
194 | 210 | | |
195 | 211 | | |
196 | 212 | | |
197 | | - | |
| 213 | + | |
198 | 214 | | |
199 | 215 | | |
200 | 216 | | |
| |||
229 | 245 | | |
230 | 246 | | |
231 | 247 | | |
| 248 | + | |
232 | 249 | | |
233 | 250 | | |
234 | 251 | | |
| |||
254 | 271 | | |
255 | 272 | | |
256 | 273 | | |
257 | | - | |
258 | | - | |
| 274 | + | |
259 | 275 | | |
260 | 276 | | |
261 | 277 | | |
| |||
272 | 288 | | |
273 | 289 | | |
274 | 290 | | |
275 | | - | |
276 | | - | |
277 | 291 | | |
278 | 292 | | |
279 | 293 | | |
| |||
282 | 296 | | |
283 | 297 | | |
284 | 298 | | |
| 299 | + | |
285 | 300 | | |
286 | 301 | | |
287 | 302 | | |
| |||
314 | 329 | | |
315 | 330 | | |
316 | 331 | | |
317 | | - | |
318 | | - | |
319 | | - | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
320 | 338 | | |
321 | 339 | | |
322 | 340 | | |
| |||
374 | 392 | | |
375 | 393 | | |
376 | 394 | | |
377 | | - | |
378 | | - | |
379 | | - | |
380 | | - | |
381 | | - | |
382 | | - | |
383 | | - | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
384 | 400 | | |
385 | 401 | | |
386 | 402 | | |
| |||
391 | 407 | | |
392 | 408 | | |
393 | 409 | | |
394 | | - | |
| 410 | + | |
395 | 411 | | |
396 | 412 | | |
397 | 413 | | |
398 | 414 | | |
399 | 415 | | |
400 | | - | |
401 | | - | |
402 | | - | |
403 | | - | |
404 | | - | |
405 | | - | |
406 | | - | |
407 | | - | |
408 | | - | |
409 | | - | |
410 | | - | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
411 | 423 | | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
412 | 437 | | |
413 | 438 | | |
414 | 439 | | |
| |||
0 commit comments