Announcement

Collapse
No announcement yet.

It's Getting Close Whether The OpenGL On-Disk Shader Cache Will Happen For Mesa 17.0

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #31
    Originally posted by bridgman View Post
    In that context, I think the priority was correct (although now that the games *are* running shader cache automatically bubbles up to a higher priority).
    I hope it does, we really need it right now (even if not as much as proper OpenCL, if we ever get it).
    ## VGA ##
    AMD: X1950XTX, HD3870, HD5870
    Intel: GMA45, HD3000 (Core i5 2500K)

    Comment


    • #32
      Originally posted by Herem View Post
      If Mesa is moving to a date based naming format
      it is not moving to date based naming format. it is moving to year based naming format

      Comment


      • #33
        Originally posted by LeJimster View Post
        Many games are just not playable now that would greatly benefit from an on-disk cache. In fact I'd put it as the number one thing missing right now.
        number one is multithreaded driver. radeonsi already has in-memory cache

        Comment


        • #34
          Originally posted by shmerl View Post
          So your idea isn't feasible.
          his idea could be slightly tweaked with caching of result of glsl parser

          Comment


          • #35
            Originally posted by pal666 View Post
            number one is multithreaded driver. radeonsi already has in-memory cache
            The in memory cache does nothing to address the issues raised here. And a multi threaded driver would be great, but shouldn't in any way take priority over this. I strongly suspect an on disk shader cache would take far less time to implement and have a large immediate benefit.

            Comment


            • #36
              Originally posted by pal666 View Post
              his idea could be slightly tweaked with caching of result of glsl parser
              Sure, but that removes about 90% of the benefit you get too, and you keep all the code complexity and extra files lying around on your hdd.

              Comment


              • #37
                Originally posted by shmerl View Post

                This doesn't make sense. The whole point of cache is to store the compiled result. Each GPU has its own architecture, so compiled shaders are specific to the GPU. They are not compatible with each other. That's the whole point of shaders being in the intermediary format, and at the same time running on different hardware with different machine instructions. They are compiled for each GPU! But you can cache them if you are on the same hardware. So your idea isn't feasible.
                Technically you could store the uncompiled shaders and compile them on loading instead of in-game, like Cemu does.
                It wouldn't shorten the loading time, quite the opposite, but it removes stuttering in-game.

                Comment


                • #38
                  Originally posted by geearf View Post

                  Technically you could store the uncompiled shaders and compile them on loading instead of in-game, like Cemu does.
                  It wouldn't shorten the loading time, quite the opposite, but it removes stuttering in-game.
                  Some games do that. Even better, why can't games take care of caching itself? They can cache compiled shaders for given GPU, and skip compilation, if next time the same GPU is used.

                  Comment


                  • #39
                    Originally posted by shmerl View Post

                    Some games do that. Even better, why can't games take care of caching itself? They can cache compiled shaders for given GPU, and skip compilation, if next time the same GPU is used.
                    They can, except not on Mesa because it will just report the binaries as invalidated each time.

                    That was the way Mesa devs were able to quickly add support for GL 4.1 (and GL_ARB_get_program_binary) without actually doing the work of figuring out how to cache compiled shaders. The new work to automatically cache shaders is fairly trivial compared to the underlying work here enabling the loading and storing of shaders at all, whether by an automatic cache or by manual GL calls from the game.

                    Comment


                    • #40
                      Originally posted by shmerl View Post
                      Even better, why can't games take care of caching itself?
                      They can.
                      I am curious about the pros and cons of drivers vs applications doing that work.


                      Aside from that I got curious, we already got in-memory shader cache, and isn't it the first major step to in disk cache? It seems like serializing the memory to disk with a few ids for the driver and game should be fairly easy, why is that not the case?

                      Originally posted by smitty3268 View Post

                      They can, except not on Mesa because it will just report the binaries as invalidated each time.

                      That was the way Mesa devs were able to quickly add support for GL 4.1 (and GL_ARB_get_program_binary) without actually doing the work of figuring out how to cache compiled shaders. The new work to automatically cache shaders is fairly trivial compared to the underlying work here enabling the loading and storing of shaders at all, whether by an automatic cache or by manual GL calls from the game.
                      well maybe that's what I was missing

                      Comment

                      Working...
                      X