04:06 imirkin: karolherbst: yeah, so precont is the address that "cont" will go to, and prebreak is the address that "break" will jump to
04:06 imirkin: this is kind of like joinat, but allows you to have a separate stack
08:50 mwk: more like a different stack entry
08:51 mwk: ie. if you brk, you obliterate all joinats/preconts/etc. currently on stack until the most recent prebrk
12:35 karolherbst: ahh, I see
12:36 karolherbst: currently need to rework my entire CFG handling, because I didn't care about loops so far. Nir is helping here a lot though and I think I can come up with something which isn't as implicit as TGSI is with that stuff.
12:36 karolherbst: like I already know the block tree and if I encounter a break, the block ends and tells me which block comes next and so on
12:37 karolherbst: so I am sure I won't need to hack those stack objects we have in from_tgsi
12:58 enyc: Hrrrrm....
12:59 enyc: ? What is the situation like these days (e.g. xorg 7.7+19 and 4.9 kernel era) with 'multiple gpus' and some sort of acceleration, all behaving themselves together ?
13:00 enyc: can I have a secondary matrox g550 PCI card or whatever, with weird x.org modelines / settings, acting purely as a framebuffer for a primary nouveau or radeon 'open driver' GPU ??
13:00 enyc: ..... some decade ago this involved xinerama and no-acceleration-possible sort of situation, iirc
13:01 enyc: MAYBE this is now a nightmare unless you use a single-card with 3/4 outputs as needed etc... ??
13:04 karolherbst: enyc: depends on what you want to have
13:04 karolherbst: enyc: you can always setup reverse prime nowadays
13:04 karolherbst: but this comes with a perf penalty, because there is a lot of communication between both GPUs
13:05 karolherbst: and then you indeed have one GPU doing all the acceleration work and the others are just displaying stuff
13:08 enyc: karolherbst: oooo what should i be reading about "reverse prime" -- particular article//documentation ??
13:10 karolherbst: just search for it, there shouldn't be too much around about it. And usually it is already kind of setup sometimes, sometimes not.
13:10 enyc: hrrm....
13:11 enyc: karolherbst: can you give me a $clue about preformation penalty / expectations there?
13:12 enyc: karolherbst: what if, i say have a PCI-e 16x nouveau or radeon something-or-other not-massively-powerful ....... and then want to framebuffer 900x700 50hzi ish off to a PCI 32bit matrox g550 ... on a reasonable AMD64 system...?
13:20 karolherbst: PCI is most likely to slow
13:20 karolherbst: you can try, but I am sure it won't be enough
13:20 karolherbst: even x16 is a bit challenging sometimes
13:20 enyc: ok fair enough =)
13:21 enyc: and, another pci-e 1x gpu ...?
13:22 enyc: I think i'm going to proof-of-concept my weird-monitor-driving, and then reconsider when i know gpus available in situ
13:22 enyc: thankyou on that front
13:23 enyc: I can of course have 'separate x display' on such other monitor, but then I guess you can't do anything like xinerama to allow applications to move around... presumably they have to have access to acceleration or not, no "not available when window moved onto that screen" [...]
13:24 karolherbst: well, you can always just test it and see how it goes
13:24 enyc: yes =)
13:24 enyc: opinions useful, to give mi insight
13:24 enyc: clues as to "terms that can be used" similarly helpful
14:16 imirkin: skeggsb: does this also need to check for chip != 0x50? https://github.com/skeggsb/nouveau/commit/374073e90929eab2f34a26553efa185de8d68354#diff-501cbdb8b40734be8ff44b9baa59c4e5R272
14:16 imirkin: skeggsb: iirc you couldn't have "kind" memory in sysram on nv50
14:29 karolherbst: imirkin: isn't Tesla here those compute cards?
14:30 karolherbst: mhh, not, it isn't
14:30 karolherbst: I got confused by the SOC thing below
14:32 karolherbst: imirkin: by the way, what should a nir pass fullfil to be considered mergeable? Something like if it can handle OpenGL stuff up to 2.1 or would you simply make this depending on the code quality?
14:32 karolherbst: not talking about turning it as the default thing
14:35 karolherbst: my minimum goal is to get it passing all the glsl-1.10 piglit tests at least and work from there up to the level we have with the tgsi one
14:35 imirkin: karolherbst: i wouldn't set specific goals
14:35 imirkin: it would have to be not-buggy
14:35 karolherbst: okay
14:35 imirkin: i.e. lacking features is fine, but having bugs is not
14:35 karolherbst: I see
14:36 imirkin: i think control flow is a must.
14:36 karolherbst: so if it would be bugfree for OpenGL 2.1 contexts, but already implements newer stuff, which isn't exposed, than it is fine?
14:36 imirkin: supporting all ops ... meh.
14:36 imirkin: yes.
14:36 karolherbst: well, I would do it like this: limit the max gl/glsl version if using nir and get somewhat the same piglit tests passed
14:36 imirkin: bug-free, btw, isn't "passes all piglits"
14:37 imirkin: bug-free is "i don't see any issues with the impl"
14:37 karolherbst: yeah, but this is an easy target for now
14:37 karolherbst: also to know what I have to implement
14:37 imirkin: (which of course doesn't lead it to truly be bug-free, but at least ... not bug-full. :) )
14:37 karolherbst: I got glxspheres running already for example, but glxgears is still a mess
14:37 imirkin: hehe
14:38 karolherbst: allthough I don't have texture support, so the text in glxspheres is screwed
14:38 imirkin: sounds like you're not completely done then :)
14:38 karolherbst: yeah
14:38 karolherbst: I am planning to work on that at least until christmas
14:38 karolherbst: so there is time
14:39 karolherbst: currently reimplementing the CFG stuff. It worked for a lot of simple cases before, but broke for stuff like while(x) { if (x) break; else x = ...}
14:40 karolherbst: well the codde is more like "sum = 0; for (i = 10; i < 14; i++) sum += i; if (sum != 46) failed = true;" but basically the same issue underneath
14:40 karolherbst: *code
14:40 imirkin: yeah ... you need to have a proper model for all this
14:41 imirkin: i don't think you can just type randomly
14:41 imirkin: you have to understand the control flow model in nir
14:41 imirkin: and the one in nvir
14:41 imirkin: and then adapt
14:41 karolherbst: I think nir already provides a usefull model here which I can translate easier than what tgsi does
14:41 karolherbst: just need to get a better understanding of the nir ones
14:42 imirkin: so just to set the bar for merging something ... if all you support are mov, add, and control flow -- that's mergeable.
14:43 imirkin: the rest is just details
14:43 imirkin: and incremental
14:43 imirkin: those are foundational.
14:43 karolherbst: okay
14:45 karolherbst: well, I would add the input/output handling to the list, because without that, it is kind of pointless to have it
14:45 imirkin: meh. it's easy and incremental.
14:45 imirkin: control flow and basic approach to converting values from one ir to the other -- that's important.
14:46 karolherbst: I see
14:46 karolherbst: well I can already convert stuff and keep track of regs/ssa values
14:46 karolherbst: just CFG is a big thing missing right now for the basics
14:47 imirkin: exactly.
14:47 imirkin: which is why it's so important.
14:47 imirkin: and has to be done first.
14:47 imirkin: i know the other stuff feels good, because, oh hey - look - shiny on screen
14:48 imirkin: but the things i mention are just a hard-required because getting them wrong is not an option
14:48 karolherbst: for fun reasons, it is actually my second patch in the series after getting nir piped into codegen, the first one is all required stuff of tracking srcs/defs
14:48 karolherbst: the CFG thing
14:50 imirkin: gtg
17:12 adya: Hello, I am new to nouveau. Doing installation of nouveau on a virtualbox. I want to start with an easy task in drm "refuse to boot if not all power connectors are plugged". But i am quite unsure of where to start from. Can someone guide me over this please. I am good in programming at C,C++,python.
17:35 pmoreau: Hello adya , usually VirtualBox exposes some “fake” GPU in the virtual machine (IIRC), and it is not Nouveau which drives that GPU. I don’t think it is recommended to do GPU driver development inside a virtual machine.
17:37 adya: oh okay, then what kind of hardware do you suggest?
17:37 pmoreau: Real NVIDIA hardware? O:-)
17:38 pmoreau: I mean, you can do debugging/implement features without the hardware at hand, but it’s going to be way more difficult, and you’ll need someone else to test it for you.
17:40 pmoreau: I have no idea if all card generations have a way of detecting that all power connectors are plugged, or if it’s only a few of them.
17:40 karolherbst: imirkin: can I connect two BBs if they aren't yet inserted in the function graph?
17:40 pmoreau: So I can’t really recommend one specific card over another one, for that particular task.
17:41 adya: Okay, so to start with I need to install nouveau on my laptop. But then for that I'll have to remove my nvidia drivers?
17:41 karolherbst: adya: well, on your laptop you won't be able to work on the task
17:41 karolherbst: this is about those power plugs you have on desktops
17:42 pmoreau: You can have both installed at the same time now, with glnvd; I think you also could do that before, with some tricks.
17:42 karolherbst: it was possible before, right.
17:42 karolherbst: but anyway, that task is not possible on a laptop
17:43 pmoreau: Right
17:43 pmoreau: Though, contributing to Nouveau with a laptop is still possible, just not that task
17:44 adya: Alright! where can I get to read to actually understand about this task?
17:44 pmoreau: Which GPU do you have adya ? (Looking for a GFXXX, GKXXX, etc. value, which you can get by running `lspci -d 10de:`)
17:49 adya: pmoreau: GM108M [GeForce 840M]
17:49 karolherbst: adya: well, the task is relly simple: detect if a power cable is connected to the GPU or not, but this is just physically impossible with your GPU
17:50 pmoreau: karolherbst: How do you detect that BTW? GPIO reading?
17:51 adya: karolherbst: then what kind of gpus are required for this?
17:52 pmoreau: A desktop GPU, which requires additional power connectors, so a GPU which consumes more than 75W.
17:55 pmoreau:is wondering what could be an easy task for a mobile Maxwell card
17:55 adya: Oh okay! And to start coding to get this I am a little confused which file to start at. Can you please provide some guidance on that
17:58 pmoreau: adya: If you only have your laptop card, it is **not** a good idea to start working on “refuse to boot if not all power connectors are plugged”. If you also have a desktop computer with an NVIDIA GPU in it, which can consume more than 75W, then it is fine.
17:58 karolherbst: adya: desktops with those 6Pin/8Pin things
17:59 karolherbst: pmoreau: maybe?
17:59 karolherbst: pmoreau: does anybody know?
17:59 pmoreau: Maybe mupuf as he’s the one who added that card?
17:59 karolherbst: well, GPIO is a good guess though
18:00 karolherbst: pmoreau: I think if you already know how that works, then implementing it should be fairly easy
18:00 karolherbst: at least to print an error/warning
18:00 adya: Ya I have a desktop in college where I can work on this
18:01 pmoreau: You can install your own kernel on those college computers?
18:01 karolherbst: adya: well, as long as you are allowed to break that machine :p jokes asied, you still would need to unplug internal stuff, and college property is usuallye a really bad idea for doing this
18:02 adya: Yes, Actually I am given this as a part of college project. So they are ready to provide hardware. :)
18:03 pmoreau: Ah OK, nice!
18:03 feaneron:wanted a college like this. Very badly.
18:03 pmoreau:too! Though he already graduated
18:04 karolherbst: adya: well, maybe you should also think about doing a GSoC project then next year
18:04 adya: But the thing is I am confused where to start with. Like this is the first time I am coding for drivers and so.
18:04 karolherbst: adya: well, I started with fixing issues I found on mine
18:04 karolherbst: and asking questions
18:04 pmoreau: Same for me
18:05 adya: Oh okay! and any references you can suggest? as in for some reading?
18:06 karolherbst: the nouveau wiki might help
18:06 adya: I really need some reference for understanding the working and stuff
18:06 pmoreau: In this case, you’ll probably need to start by looking at what NVIDIA does if you do not plug the power connectors: does it emit a warning/error message? Is it reading the state of a specific GPIO, or some register?
18:06 karolherbst: anyway, gtg
18:07 pmoreau: (If it does emit a message regarding the connectors, then it has a way to detect that. If it doesn’t, hard to say.)
18:07 adya: Alright! I'll start with that right away! Thanks for the help karolherbst and pmoreau
18:07 pmoreau: adya: mupuf might have more information about it, but he doesn’t seem to be available right now.
18:08 pmoreau: Also, be aware that the behaviour might change between different card generations.
18:08 adya: Oh okay, pmoreau . I'll leave a message to mupuf.
18:09 feaneron: wondering how extensive and hard would be bootstrapping a vulkan driver for nouveau
18:10 feaneron:runs piglit
18:10 pmoreau: feaneron: IIRC skeggsb was saying that some more cleaning/rewriting was needed in the kernel, then you’ll need the implement the API and be able to translate SPIR-V to NVIR.
18:11 feaneron: right. all in mesa level appearently
18:12 pmoreau: There are kinda two different WIP for SPIR-V to NVIR, but they lack quite a few things.
18:12 feaneron:never read a single message from skeggsb yet
18:12 pmoreau: Well, except the kernel part :-D
18:13 feaneron: heh of course :)
18:13 pmoreau: He is not the most talkative guy around here, for sure :-D Plus he’s on a quite different timezone, which does not help.
20:53 mupuf: Sorry guys, I had a power cut today, and I forgot to start IRC again
20:57 mupuf: if adya comes back, tell him it is only a matter of reading a GPIO
20:57 mupuf: As to what to do, we should probably disable acceleratio
20:58 mupuf: some GPUs refuse to POST entirely if the GPIO is not plugged though (the new ones)
20:58 mupuf: but old ones had no problems
21:11 daidoji: hello #nouveau, anyone seen anything like this before? https://gist.github.com/daidoji/6a8f2e5d1da3979cea2f03badfa094f3
21:13 daidoji: its happened a few times, my X session always freezes up and I lose keyboard responsivity (none of the typical Unix ways of getting that back or switching to a virtual console work) and I either have to ssh in from the outside and kill the X session directly or reboot
21:14 daidoji: I'm running this kernel version '4.9.67 #2 SMP Tue Dec 5 16:29:07 CST 2017 x86_64 Intel(R) Core(TM) i7 CPU M 620 @ 2.67GHz GenuineIntel GNU/Linux'
21:14 daidoji: with this nouveau xf86-video-nouveau-1.0.15-x86_64-1
21:14 daidoji: (Slackware package if that helps anyone)
21:17 orbea: daidoji: just a guess, but try a newer kernel, there were improvements for nouveau since 4.9
21:20 daidoji: orbea: okay, I kind of just run current on my distro, any particular kernel you think I should target?
21:22 orbea: the latest stable?
21:23 orbea: i know there was lot of stuff down in 4.10 and maybe 4.12 too?
21:23 orbea: *done
21:24 daidoji: orbea: roger, I'll give that a try and see if it clears up. Thanks
21:25 orbea: if not, come back and someone else who knows more than me might have a better idea
21:33 daidoji: roger
21:37 pmoreau: mupuf: No worries. Any idea on which gen it would be better to try it out? Can all gen detect it?
21:38 mupuf: teslas are probably the worst ones
21:38 mupuf: pretty sure kepler boots without it
21:39 pmoreau: I was also thinking Kepler+ would be the best.
21:40 pmoreau: I’ll try to keep an eye tomorrow on IRC to see if he/she comes back.
22:05 mupuf: pmoreau: no, no kepler+ if he plans on working on this project
22:05 mupuf: fermi or tesla is a safer bet
22:06 mupuf: oh, fun, avast released an open source decompiler: https://github.com/avast-tl/retdec
22:09 mupuf: may be useful for the person who was working on coreboot :)