tag:blogger.com,1999:blog-27901662.post1777816565470959436..comments2024-03-28T07:30:33.361+00:00Comments on Zack Rusin: Intermediate representation againZackhttp://www.blogger.com/profile/16222054590923441165noreply@blogger.comBlogger10125tag:blogger.com,1999:blog-27901662.post-57953062119216225472012-02-24T09:59:00.885+00:002012-02-24T09:59:00.885+00:00If TGSI is that close to Microsoft's shading l...If TGSI is that close to Microsoft's shading language, would Wine be likely to understand it?Michaelnoreply@blogger.comtag:blogger.com,1999:blog-27901662.post-18862699914250287482010-10-31T20:38:17.523+00:002010-10-31T20:38:17.523+00:00@Christopher Friedt: I think you're missing Za...@Christopher Friedt: I think you're missing Zack's point. What he's saying is that LLVM backends for drivers don't pop up overnight, so it's not practical to wait for direct LLVM code-generators to appear for every supported driver.<br /><br />Instead, an LLVM to TGSI translator would provide compatibility with existing drivers. This allows existing drivers to use the LLVM infrastructure indirectly and then switch to a direct LLVM code-generator when it's ready.Bryanhttps://www.blogger.com/profile/04978388310314543269noreply@blogger.comtag:blogger.com,1999:blog-27901662.post-59777373439916724632010-10-31T00:15:33.764+01:002010-10-31T00:15:33.764+01:00@Zack
It's not that ridiculous. Basically all ...@Zack<br />It's not that ridiculous. Basically all of the major players have to provide an instruction set that interfaces with llvm since they all need provide graphics for OSX at some point or another. OSX uses llvm for loads of things, including gpgpu task. If you outline such a project (and draw lines carefully), then they might agree to each fund one developer for one year to come up with a clean-roomish llvm implementation, then the open-source community could work on stitching things together.Anonymoushttps://www.blogger.com/profile/05896336560457157090noreply@blogger.comtag:blogger.com,1999:blog-27901662.post-12411450117404661132010-10-30T16:53:13.483+01:002010-10-30T16:53:13.483+01:00@knue: I think you're misunderstanding somethi...@knue: I think you're misunderstanding something. We can't just use "LLVM completely" because it implies that we would have to fork our entire code-base for at least a year to write a LLVM backend for every piece of hardware that we support right now. Clearly that's ridicules, we need to keep things working. At this stage LLVM doesn't help with register allocation because every GPU has different registers and we have no backends for any of them. Also there is no first translation it's <br />Source lang -> LLVM ir -> TGSI -> drivers<br />and obviously drivers that will be able to use LLVM ir will use it directly and once all of them will have LLVM backend than and only then we'll be able to simply remove TGSI from the equation.Zackhttps://www.blogger.com/profile/16222054590923441165noreply@blogger.comtag:blogger.com,1999:blog-27901662.post-72491344188353192952010-10-30T11:04:53.221+01:002010-10-30T11:04:53.221+01:00But if you use llvm completely, things like regist...But if you use llvm completely, things like register allocation can be done by llvm. Besides that first translating to TGSI can introduce non optimal code. Is it possible to support both approaches? Newer drivers could just use llvm and the older ones can stick to TGSI.knuehttps://www.blogger.com/profile/15094369992878009398noreply@blogger.comtag:blogger.com,1999:blog-27901662.post-9261180669169273632010-10-29T18:19:39.348+01:002010-10-29T18:19:39.348+01:00I tried out clover but couldn't even get it to...I tried out clover but couldn't even get it to compile, is there a specific llvm version needed?Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-27901662.post-91125074815003872952010-10-29T15:27:30.392+01:002010-10-29T15:27:30.392+01:00@Bryan: Right after Tungsten Graphics and all of i...@Bryan: Right after Tungsten Graphics and all of its assets have been acquired by another company :) Ah, and thanks!<br />@Christoph: Yea, it's its similarity to TGSI that interests me in this context rather than its relevance as a direct GPU code-generator.<br />@knue: Ultimately removing TGSI would be the goal, but for now we have a number of drivers which use TGSI and keeping them working is quite frankly a must. So rather than writing a LLVM code-generator for every driver a LLVM code-generator for TGSI would keep all of the drivers working.Zackhttps://www.blogger.com/profile/16222054590923441165noreply@blogger.comtag:blogger.com,1999:blog-27901662.post-35619080029063019202010-10-29T13:00:03.156+01:002010-10-29T13:00:03.156+01:00I've read a blog post that you wanted to use l...I've read a blog post that you wanted to use llvm for IR transformations. So why don't you just use llvm assembly as IR and write code generators for llvm?<br /><br />Having this<br />compiler -> llvm -> gpu code<br />instead this<br />compiler -> TGSI -> llvm -> TGSI -> gpu code<br />seems better.knuehttps://www.blogger.com/profile/15094369992878009398noreply@blogger.comtag:blogger.com,1999:blog-27901662.post-64781280965957844412010-10-29T10:00:01.333+01:002010-10-29T10:00:01.333+01:00Just want to mention that PTX doesn't correspo...Just want to mention that PTX doesn't correspond 1:1 to the hardware instruction set and that ptxas still has to do register allocation (obviously) and quite some optimization.Christophnoreply@blogger.comtag:blogger.com,1999:blog-27901662.post-43232961086570660472010-10-29T00:28:51.487+01:002010-10-29T00:28:51.487+01:00When did TGSI stop standing for Tungsten Graphics ...When did TGSI stop standing for Tungsten Graphics Shader Infrastructure and start standing for Tokenized Gallium Shader Interface?<br /><br />Anyway, it's great to see you post again after about three months.Bryanhttps://www.blogger.com/profile/04978388310314543269noreply@blogger.com