08:18Hadit: the screen on a mac book retina stays black on kernel 3.16 and higher , the problem is caused by "nouveau E[ PDISP][0000:01:00.0] 00:0006:0f44: link training failed"
08:19Hadit: we're about to bisect it, but i think we may missed something, because were are inside some intel_drm stuff, which isn't even loaded in.
09:30grant1: Hi I'm hoping that someone could help me troubleshoot installing nouveau drivers for my laptop
09:31grant1: I have a new laptop that I put ubuntu on, and it doesn't automatically recognize my Gefroce gtx 860m gpu
09:31grant1: so I was pointed to download from nouveau
09:31grant1: but i dont know where to start
09:31grant1: pretty new to linux
09:32grant1: can anyone help me?
09:33prg_: is that a kepler? that should work, what makes you think it's not recognized?
09:33prg_: awfully old kernel, like 3.2?
09:35grant1: what do you mean?
09:36grant1: Well when i go into system info it lists my integrated gpu as the graphics card
09:37prg_: ah, optimus? never used that
09:37grant1: my kernel is 3.16.0-33-generic
09:37grant1: yea idk, I installed the drivers that I got from nvidia website
09:37grant1: and it litterally pooped on my computer
09:37grant1: like I lost all gui
09:37grant1: and had to reinstall ubuntu
09:39prg_: pastebin output of xrandr --listproviders
09:40prg_: (or just paste it, if it's just two lines...)
09:40grant1: Providers: number : 1
09:40grant1: Provider 0: id: 0x49 cap: 0x9, Source Output, Sink Offload crtcs: 4 outputs: 6 associated providers: 0 name:Intel
09:40grant1: thats the output
09:40prg_: ah, hm
09:40prg_: pastebin dmesg
09:41grant1: how do I pastebin (sorry for being a noob)
09:43prg_: if the output fits into the terminal, just copy from terminal and paste into some site like pastebin.com
09:43prg_: hm doesn't mention nouveau
09:44grant1: It doesn't list any available drivers when I go to "Additional Drivers"
09:44grant1: Is it possible that the gpu is supported by linux?
09:44prg_: lspci -nn -d 10de:
09:46prg_: just -nn, not --nn
09:46grant1: oh sorry
09:47grant1: 01:00.0 3D controller : NVIDIA Corporation GM107M [GeForce GTX 860M] [10de:1392] (rev ff)
09:48prg_: gm107... might work with a very new kernel afaik
09:48prg_: but not too sure
09:48grant1: what do you suggest I do?
09:49grant1: do I not have the newest kernel?
09:49prg_: newest for your distro possibly
09:49grant1: im on ubuntu 14.04
09:50prg_: not sure if it's worth updating, maybe someone else here knows how gm107 works nowadays
09:55hakzsam: does someone have a radeon card with Catalyst and piglit installed? I would need to run some tests related to AMD_performance_monitor
09:58whompy: hakzsam: You may have better luck with that request in #radeon
10:00hakzsam: yes, but I'm pretty sure that someone of the Nouveau community must have a radeon card :)
10:00hakzsam: let me ask on #radeon
11:46pmoreau: hakzsam: I have one! At home though… :D
12:17hakzsam: pmoreau, go home then :p
12:17pmoreau: Ah ah ah! :p
12:57mlankhorst: why would I run the fglrx drivers voluntarily, even if i had a radeon card?
12:57imirkin_: mlankhorst: because you desperately need GL4.x features?
12:59martm_: mlankhorst: hey dutch intelligence, well you know what is the difference to end user, basically the vt swtich needs to be fast, i thought its ok to bring windows drivers in
13:00martm_: there are arguments why open source drivers are better, some cases where the most final blob is sent to graphics hw, where less translation is done, but in the end open source graphics can mature later
13:01martm_: when you are ready with all the stuff, just let others know
13:45martm_: i am pretty despised, but imo kygo came to help
13:48martm_: what better then during the last days to hear some solide flute melody you know thanks and go fuck yourself
14:09Ident: imirkin_: someone made a apitrace
14:09imirkin_: Ident: awesome
14:09Ident: about the problem i mentioned to you some days ago (stuff rendering right on all windows drivers and some linux drivers)
14:10Ident: i found out a bit more: it seems to also not work on ati as well as nvidia gpus
14:10Ident: and also it seems not to work on some proprietary drivers
14:10imirkin_: yeah. quite honestly i don't remember what your issue was
14:10imirkin_: iirc you wanted me to install some thing that i couldn't figure out how to build :)
14:11Ident: our library (CEGUI, a gui rendering library) rendered the whole GUI upside down and downscaled (towards the middle to ~33% of the size)
14:11imirkin_: oh right yeah
14:11imirkin_: so... do you have the apitrace?
14:11imirkin_: care to share with the class? :)
14:11Ident: can i pm it?
14:11Ident: or do you prefer it to be public
14:12imirkin_: public would be better, but pm is fine too
14:12Ident: ok public then
14:12imirkin_: i guess it's most likely that only i would be looking at it
14:12Ident: only look at the 2nd last post
14:12imirkin_: which trace do i want? legacy or gl3?
14:12Ident: both dont work
14:12imirkin_: in diff ways or in the same way?
14:12Ident: gl3 = opengl 3.2+ core profile
14:13Ident: legacy = some opengl 1.4 code used for rendering, mostly fixed function pipeline
14:13imirkin_: ok, let's do gl3.2 core... that's easier to debug
14:13Ident: whatever the issue is, it appears in both
14:13imirkin_: at least on modern gpu's
14:13Ident: yea i d to the same
14:13Ident: i dont liked fixed function, gives me nightmares
14:13imirkin_: my gl1.x knowledge has somewhat atrophied too
14:13Ident: mine too
14:14imirkin_: [not that there was a ton to begin with...]
14:14Ident: yup same here
14:14Ident: luckily my uni forced us to do 3.2+ core profile
14:14Ident: in hindsight this was a good choice by them
14:14imirkin_: so i assume that the intent was for that thing to take up the whole screen?
14:14Ident: yes exactly
14:14imirkin_: i just ran it on i965 mesa 10.3.7
14:15imirkin_: and the failure was different than you describe, but definitely very failure-y
14:15Ident: mind to share a screenshot?
14:15imirkin_: yeah, working on it ;)
14:15imirkin_: need to remember how to tell retrace to do that
14:16imirkin_: oh wait, i lied. it's exactly as you describe
14:17Ident: at least it is consistently wrong
14:17Ident: that seems easier to resolve to me
14:17Ident: looks familiar ;)
14:17imirkin_: so this was with i965, which is a different driver than nouveau
14:17imirkin_: (and different hardware, obviously)
14:17imirkin_: and it doesn't even use the gallium stack
14:18imirkin_: so either you're doing something consistently wrong
14:18Ident: i will post this information in the issue tracker
14:18imirkin_: or it's a high-level mesa bug
14:18imirkin_: (which i certainly wouldn't discount!)
14:19Ident: is mesa used everywhere on linux distros?
14:19imirkin_: mesa is the container for all the open-source 3d drivers on linux
14:20Ident: what about proprietary ones
14:20Ident: we got some error reports using proprietary drivers as well, it seems
14:20imirkin_: those are all separate and made by the relevant vendors
14:20Ident: that would hint towards an issue on our side
14:20imirkin_: so the flip issue
14:21imirkin_: is most likely that you're rendering to an fbo instead of the winsys buffer
14:21imirkin_: and not accounting for the flip?
14:21imirkin_: i got nothing for the "squish" issue
14:21Ident: yea if it was just the flip
14:21imirkin_: you could be doing something dumb like glPixelZoom, but that seems unlikely
14:21Ident: then i wouldnt be so confused
14:21Ident: i dont think we use that ever
14:21Ident: especially not in my gl3 renderer
14:21imirkin_: yeah, i only found out about that like a week or 2 ago
14:22Ident: both renderers use a class for FBOs which is only used on linux
14:22Ident: if the error is there it would explain why it doesnt appear on windows
14:22imirkin_: i'd look there :)
14:22Ident: but on the other hand
14:22Ident: actually i need to check if this is also true for opengl3
14:23Ident: because opengl 3.2+ has fbos in core
14:23imirkin_: fwiw i just verifeid that the "legacy" trace also has the same issue on i965
14:24Ident: i measured the squish once in photoshop and it is about 1/3 but not exactly, it seems
14:25imirkin_: yeah, there's no "obvious" way to mess it up like that
14:28Ident: i already see one issue
14:28imirkin_: amazing what code review can turn up ;)
14:29Ident: well i dont see the real issue yet
14:29Ident: i only see that opengl 3.2+ renderer on linux distros still uses some other FBO class
14:29Ident: thats not necessary right? i should be able to use the gl functions as provided by opengl 3.2+ core for FBOs no matter what OS
14:30Ident: unless it is about host-window handling
14:30imirkin_: yeah, note that fb 0 is special
14:30imirkin_: i.e. the winsys fb
14:30Ident: the display one?
14:31imirkin_: it's flipped relative to fbo's
14:31imirkin_: (to maximize confusion)
14:31Ident: what do you mean by flipped
14:31imirkin_: y is upper left vs lower left
14:31imirkin_: i never remember which is which
14:32Ident: ah ok
14:32Ident: i get you now
14:32Ident: is there a difference on unix in that regard?
14:34Ident: actually it doesnt make sense if this was it
14:34Ident: because then it would work for nobody
14:34imirkin_: not afaik
14:34imirkin_: it's a GL thing
14:34Ident: i still dont get why it works for some but for some not, i see absolutely no pattern
14:35imirkin_: well, it sounds like it doesn't work for anyone using mesa
14:35imirkin_: and it doesn't work on the nvidia blob drivers
14:35imirkin_: at least not the 304.x revision
14:36imirkin_: there aren't a whole lot of other possibilities on linux -- there's the amd catalyst proprietary drivers
14:36imirkin_: which tend to just not work at all in the first place
14:36imirkin_: or have horrible bugs if you ever fall off the "some popular game does this" paths of GL
14:47imirkin_: ... and that's it. no other desktop gpu manufacturers that have linux driver presence
14:47imirkin_: SiS, Matrox, VIA -- they've all fallen by the wayside
14:49airlied: there are no other GPU manufacturers fullstop
14:49airlied: desktop side
14:49Ident: one guy wrote about the issue appearance: "This happened to me when I updated my linux from Ubuntu 11.04 to Mint 17.1 and updated my graphics drivers to nvidia-331.113."
14:49Ident: he later wrote: "Reverted nvidia drivers to 304.125 for shits and giggles, same result."
14:50Ident: could it be that the issue is somewhere in the OS and not the driver?
14:50imirkin_: airlied: didn't VIA make a DX9 gpu?
14:50glennk: i think matrox actually made a dx9 gpu long ago
14:51imirkin_: Ident: thoroughly unlikely... much more probable that it's an issue in the application
14:51Ident: how would an issue in the application become apparent after a system update
14:51Ident: any ideas?
14:51imirkin_: let me look at the trace to see if i identify anything obviously wrong
14:51Ident: the opengl setup is not terribly complicated
14:51airlied: imirkin_: you woudn't use those gpus on windwos either
14:51imirkin_: Ident: newer version of the application was installed?
14:52airlied: maybe its using swrast :)
14:52Ident: imirkin_: they built newer and older versions from source
14:52Ident: no difference
14:52imirkin_: Ident: well something changed somewhere :)
14:52Ident: at least the issue reporter did that, he installed 0.8.0 of our library which is quite old
14:52Ident: i was that far too
14:52imirkin_: could be that glfw changed or whatever you were using
14:53Ident: see thats another thing
14:53Ident: they used all sorts of libraries
14:53Ident: not just glfw
14:53Ident: the one guy use sgml or how its called
14:53Ident: also SDL2
14:53Ident: same result
14:54imirkin_: anyways, i can say with smoe level of conviction that it's not an issue in the nouveau backend
14:54Ident: yea i think so too
14:57imirkin_: Ident: so i'm looking at your code
14:57imirkin_: the apitrace
14:57imirkin_: and i see that you upload a modelViewPerspMatrix
14:57imirkin_: and i haven't done the math, but *that* seems to be is what's flipping things
14:57Ident: since its a transformation it can flip things yes
14:58Ident: the same matrix is used on windows so it seems strange it would lead to different results
14:58imirkin_: Ident: ok, well print the values on windows
14:59Ident: hardcoding the matrix on windows?
14:59Ident: and see what happens?
14:59imirkin_: glUniformMatrix4fv(location = 0, count = 1, transpose = GL_FALSE, value = [-0.632285, 0, 0, 0, 0, 1.16823, 0, 0, 0, 0, 1.66667, 1, -181.466, -363.905, 645.023, 1935.07])
14:59imirkin_: no, just print out the values being uploaded
14:59Ident: oh ;)
15:00Ident: i gotta rebuilt it quickly
15:01imirkin_: curious, i also see the matrix being uploaded twice
15:01imirkin_: first time is: 90918 @0 glUniformMatrix4fv(location = 0, count = 1, transpose = GL_FALSE, value = [-0.632285, 0, 0, 0, 0, 1.16823, 0, 0, 0, 0, 1.66667, 1, 605.729, -605.729, 645.023, 1935.07])
15:01imirkin_: second time is: 90924 @0 glUniformMatrix4fv(location = 0, count = 1, transpose = GL_FALSE, value = [-0.632285, 0, 0, 0, 0, 1.16823, 0, 0, 0, 0, 1.66667, 1, -181.466, -363.905, 645.023, 1935.07])
15:01imirkin_: third time is: 90927 @0 glUniformMatrix4fv(location = 0, count = 1, transpose = GL_FALSE, value = [-0.632285, 0, 0, 0, 0, 1.16823, 0, 0, 0, 0, 1.66667, 1, -181.466, -363.905, 645.023, 1935.07])
15:02imirkin_: er wait, ignore that "first", that's from a diff draw
15:02imirkin_: and also that first is from the draw that e.g. flips the background
15:03Ident: so the first one is the relevant one?
15:03imirkin_: it has that star/planet background as its texture
15:03Ident: the reason you see other calls is that we do RTT
15:03imirkin_: and it draws that onto the fb, which ends up with it flipped
15:03Ident: yes thats the relevant one
15:03imirkin_: (and compressed)
15:04imirkin_: the shader is just http://hastebin.com/adokudupib.avrasm
15:05imirkin_: interesting, i don't see anything that indicates how the VAO is configured
15:06imirkin_: i forget how that's done tbh
15:06imirkin_: but somethign somewhere is supposed to say that it's e.g. a sequence of floats or whatever
15:06Ident: in the shadeR?
15:06imirkin_: no, in the GL
15:06Ident: i m pretty sure i did that
15:06Ident: its interleaved
15:06imirkin_: which attributes are boudn to which vbo things, etc
15:06imirkin_: what's the gl call?
15:06Ident: yea i do that
15:06Ident: wait a sec
15:07imirkin_: i'm blanking on how that's normally done
15:07imirkin_: but something definitely feels missing
15:08imirkin_: oh i see
15:08imirkin_: in the first frame you do glBindAttribLocation
15:08imirkin_: and then you do glVertexAttribPointer
15:09imirkin_: but that's only done in the first frame...
15:09Ident: first call: glUniformMatrix4fv(0, 1, GL_FALSE, (2.0992785, 0, 0, 0, 0, -3.7320509, 0, 0, 0, 0, 1.666, 1.0, -1343.5382, 1343.5382, 447.84607, 1343.5383)
15:09Ident: imirkin_: you dont need to do that more than once
15:09Ident: thats what vaos are for
15:09Ident: unless you create a new vao of course
15:10Ident: then you need to do it again
15:10imirkin_:is weak on those details
15:10Ident: the vaos are fine
15:11Ident: i m pretty sure
15:11Ident: i typically read the opengl spec
15:11Ident: of course i could have maken a mistake, but the current issue doesnt look like its coming from a malconfigured vbo or vao
15:11Ident: i ve had those before and you typically get crazy triangles
15:11Ident: (or colours or whatever attributes)
15:13Ident: hmm odd
15:14Ident: my 6th matrix value always stays the same no matter if i resize my window or not
15:14Ident: yet the one you gave me is different
15:15Ident: its the m11 value of the view persp matrix
15:18Ident: those matrix values are unfortunately quite abstract and i cant debug-step into their creation process
15:19imirkin_: i'm trying to trim the trace down right now
15:19Ident: i m debugging the matrix generation locally
15:20Ident: but not sure how helpful that is
15:20Ident: would also be interesting to see what happens if one just scales the whole matrix by 3 and flips it
15:20Ident: like if this really resolves it
15:23Ident: we use glm
15:23Ident: maybe the linux distros use a very new glm
15:23Ident: sizing by approximately 3 sounds like approximately Pi
15:23Ident: am i onto something?
15:24Ident: i ll get a new version of glm
15:29Ident: rofl: fatal error "GLM requires Visual C++ 2010 or higher" <-- thats what I get for trying to support ancient compilers (i used vs 2008 in this case)
15:34imirkin_: Ident: so here's a mini trace... that last draw i cut it off on makes it obvious that things are flipped: http://filebin.ca/1wsVL0mUjGO3
15:38imirkin_: pull it up in qapitrace and see if it seems awkward
15:38imirkin_: also replay the trace on your machine
15:45Ident: it closes the window immediately again
15:45Ident: i use the CLI via "apitrace replay"
15:48Ident: if i use -w it is just black
15:50Ident: i have good news
15:51Ident: i can reproduce the issue on my windows machine
15:51Ident: the issue was indeed glm, one of the dependencies we have
15:51Ident: i didnt expect that
15:51Ident: thanks a lot for the help, i wouldnt have gotten to this point so fast without you
15:59Ident: its actually quite an obvious cause (and quite trivial too) if seen in hindsight, but thats often the case with those "inexplainable" issues ;)
16:00Ident: didnt see the forest through the trees
16:07imirkin: Ident: yeah, once you know what the issue is, the cause of the problem is often quite apparent :)
16:08imirkin: what's glm btw? a linear algebra package?
16:09imirkin: looks (a bit) like it -- http://glm.g-truc.net/0.9.6/index.html -- cool
16:09Ident: imirkin: it is a really really great library for maths specifically for opengl stuff
16:09Ident: you remember glu and glut and whatever those libraries were?
16:09imirkin: i remember glutTeapot() :)
16:09Ident: also the whole fixed-function stuff
16:09Ident: basically glm gives functionality that you would want to have when doing opengl 3.2+ core profile
16:10Ident: for example glm::perspective
16:10Ident: or lookAt
16:10Ident: translate,rotate, etc etc., it has a whole bunch of math functions and structs, and it sticks very very closely to the opengl spec (specifically for glsl functions)
16:11Ident: i even use it for direct3d ;)
16:11Ident: i scrapped all the direct3d dependencies (effects libraries etc) and just use the essentials there, and use glm to create the matrices and do the maths
16:11Ident: probably one of the best open source libraries i used, the guy who maintains it is very active
16:13Ident: also it offers a mechanism to retrieve pointers to the data structures whenever you need them for openGL function calls, so it always feels "safe" and clean
16:15Ident: gluPerspective, gluOrtho2d, gluLookAt, those functions are basically recreated there