00:08 orbea: I (and others) are getting segfaults (Sometimes it just locks up requiring dolphin to be killed via ssh) after around 20-30s of running dolphin-emu with asynchronous ubershaders. The backtrace seems to indicate its a nouveau issue, is this right? https://pastebin.com/YUcaH3ie Is this right?
00:09 orbea: i tried mesa commits back to 2017 without finding a working commit, but I do think this worked at some point....
01:40 imirkin: orbea: hmmm a null bo? yeah, that feels like async is doing more than compiling shaders
01:40 imirkin: probably also doing some "test draws", which mess everything up
01:40 imirkin: why on earth is it calling glFinish?
01:42 HdkR: imirkin: "If we don't do this, some driver can lock up (e.g. AMD)"
01:42 HdkR: Is the comment in the source
01:44 HdkR: It also binds the vertex attribute that was set at that point in to time work around the vertex attribute optimization in the Nvidia blob
01:44 imirkin: HdkR: and if you do, you lock up other drivers, like nouveau ;)
01:45 HdkR: at that point in time to work around*
01:57 orbea: so is this something that should be fixed in mesa or dolphin?
01:58 imirkin: i mean, nouveau should deal with multiple GL contexts
01:58 nyef: Longstanding known issue in nouveau, you might as well work around it in dolphin for the time being?
01:58 imirkin: but it doesn't
01:58 orbea: ah, i see
02:00 orbea: can just not use asynchronous ubershaders I guess...
02:11 HdkR: orbea: Dolphin can implement a bug in their DriverDetails system to avoid the VAO binding and glFinish when Nouveau is being used
02:13 orbea: cool to know, guess that should be passed along to Stenzek?
02:13 HdkR: Yep
02:13 HdkR: Would only take a few minutes to write the code
07:46 MaximLevitsky: Hi!
07:48 MaximLevitsky: I have the 1080Ti here, and I wonder how well nouveau should support it. I bought it for gaming mostly and I use it for pci pass through to a VM, but still use it in the host sometimes
07:49 MaximLevitsky: The blob gets on my nerves....
07:50 gnarface: MaximLevitsky: last i heard it still can't reclock the ram so it's basically crippled for gaming under nouveau. no sign of nvidia forking over the encryption key to unlock it, either. for gaming the binary blob is unfortunately the only serious choice on that card.
07:50 gnarface: i hear the 780 Ti's work great though ...
07:50 MichaelLong: MaximLevitsky, same here, I only use it for pass-through right now
07:50 MaximLevitsky: I know... but if I extract the reclocking firmware from the blob, it would work?
07:54 MichaelLong: MaximLevitsky, no it is not that easy AFAIK, the firmware would only allow you to do more sophisticated function but the clocking itself needs to be done in the driver, it is parly possible with way older cards right now.
07:57 MaximLevitsky: I understand. Fucking nvidia. My next card will be vega for sure
07:58 MichaelLong: mine will still be a nvidia despite all that
08:00 MaximLevitsky: When I bought my card, vega wasn't out yet, and I wanted something that works well for GPGPU for doing serious work in rendering for my girlfriend. We don't use this much, so no more nvidia.
08:00 MichaelLong: I'm following the topic lightly, and using recent amd cards in a vfio-setup is hit and miss, plus the cards are not competitive
08:00 karolherbst: MaximLevitsky: no reclocking on those GPUs sadly
08:01 karolherbst: everything is kind of locked down there, so it requires signed firmware
08:01 MaximLevitsky: MichaelLong: that what I am afraid too, but I give it a try. It improves over time
08:01 annadane: i am avoiding nvidia in future as well
08:01 MichaelLong: MaximLevitsky, nah it doesn't really
08:01 annadane: wish i had asked about this before buying my current computer
08:01 MichaelLong: cards that are known to have reset problem will have them. it is not the devs priority to fix that.
08:02 MaximLevitsky: MichaelLong: Exactly what I was thinking about. I think they did improve something about that reset bug
08:03 MaximLevitsky: Anyway, what a sad world we live at it, with all these locks. I almost wish that encryption wasn't possible despite all of its benefits.
08:03 MichaelLong: btw. the 1080 runs nicely with noveau in a pass-through-setup :)
08:04 MaximLevitsky: nouveau in the guest?
08:04 MichaelLong: yes
08:04 MaximLevitsky: Good to know. So far didn't need a Linux guest here.
08:04 MaximLevitsky: *I didn't
08:05 MaximLevitsky: Might need soon. I joined redhat last week (the KVM team) :-)
08:05 MichaelLong: yeah it is more or less a test system with the same specs as my "gaming-vm".
08:05 MichaelLong: MaximLevitsky, ah nice :)
08:05 annadane: incidentally, do people prefer AMD or Intel for ethical reasons? apparently they're about the same
08:06 annadane: and functionality with linux etc
08:06 MaximLevitsky: AMD is a *bit* better
08:06 MaximLevitsky: Intel has SGX and they don't SGX = DRM on steroids
08:07 annadane: i guess i'll buy a stock ryzen, or whatever
08:07 MaximLevitsky: DRM for running software black boxes, and it actually has a chance to be unbreakable.
08:07 annadane: they do or don't?
08:07 MaximLevitsky: *Assuming that they fix all their spectre/meltdown/etc bugs.
08:11 MaximLevitsky: annadane: AMD doesn't have SGX, but they do have a 'secure coprocessor' and they already started using it
08:11 annadane: AFAIK the PSP is not as bad as the IME
08:12 MaximLevitsky: I bet that it will be eventually....
08:12 MaximLevitsky: The point it that they discovered that software DRM is actually theoretically possible. Its done by making the CPU not trust YOU with its own private keys.
08:13 MaximLevitsky: So unless you open the silicon, its game over.
08:13 MaximLevitsky: :-(
08:13 annadane: it's stupid. i hope RISC-V takes off
08:14 MaximLevitsky: I too, I am praying for this to happen.
08:15 karolherbst: RISC-V doesn't protect against such things
08:15 karolherbst: it isn't open hardware, just the ISA is kind of open
08:15 karolherbst: more or less
08:15 MaximLevitsky: Yes, but it adds some competition to the scene
08:15 karolherbst: true
08:16 karolherbst: nvidia plans to use risc-v for the co-processors on the GPUs
08:16 HdkR: hehe
08:16 MaximLevitsky: Indeed :-(
08:17 karolherbst: well, makes it easier for us
08:17 HdkR: ARM's one day smear campaign on SPIR-V was great
08:17 karolherbst: so we can write firmware for non secure ones easily
08:17 karolherbst: true
08:17 karolherbst: well, they weren't wrong though
08:17 HdkR: True, almost all the points were valid
08:18 karolherbst: which point wasn't?
08:18 MaximLevitsky: To be honest the only real solution to that is when someone, someone like Linus Torvalds comes up with a way to create an inexpensive silicon process so that we as a community could design our own chips.
08:18 HdkR: The one I don't remember and now the site is gone so woop
08:18 karolherbst: HdkR: :D
08:18 MaximLevitsky: Otherwise the silicon world is closed and full of such shit
08:19 MaximLevitsky: In fact even when running Linux these days, the system is barely open source, due to so much firmware running everywhere.
08:19 karolherbst: true
08:19 karolherbst: but having an open ISA helps a lot
08:19 karolherbst: because you don't have to care about the tooling
08:20 MaximLevitsky: I understand that firmware is needed, and it can be closed source, but the assumption always was that firmware is relatively simple and dumb
08:20 HdkR: karolherbst: How much time is wasted documenting the ISA each time it changes on Nvidia do you think?
08:20 karolherbst: less time than making it work with the older one
08:20 MaximLevitsky: These days each firmware is full blown OS......
08:20 karolherbst: MaximLevitsky: *toy OS
08:21 karolherbst: at least the linux one is based on a toy OS
08:21 karolherbst: uhm
08:21 karolherbst: intel one
08:21 MaximLevitsky: I understand what you mean :D
08:21 karolherbst: no, literally
08:21 karolherbst: but yeah
08:21 MaximLevitsky: Minux is for sure a toy OS :D
08:22 karolherbst: allthough v3 was made for embedded systems...
08:23 HdkR: karolherbst: er, I mean. Volta - New ISA, have to redocument all the crap. Maxwell - New Isa, had to redocument....Kepler? Or was it Fermi..?
08:23 karolherbst: HdkR: kepler also got a new one
08:23 HdkR: lol, derp
08:23 MaximLevitsky: my name at redhat is mlevtsk, so I soon will use it here too
08:23 karolherbst: gk110
08:24 MaximLevitsky: *mlevitsk
08:24 HdkR: It's such a waste of time running the cuda compiler through its paces to get the isa documentation
08:24 karolherbst: HdkR: oh well
08:24 karolherbst: HdkR: intel is changing their internal ISA as well
08:24 HdkR: That'll be fun to read the documentation from 01.org :P
08:24 karolherbst: they just have the disadvantage that they have to add a compatibiliy layer for x86
08:25 karolherbst: it's secret
08:25 HdkR: Oh, the uarch on the CPU you mean?
08:25 karolherbst: sure
08:25 MaximLevitsky: The funny thing is that when I worked at Intel, my name was mlevtsky (They forgot the 'i'), and here due to 8 char limit, I lost 'y' at the end of my name :-)
08:25 HdkR: That's not public facing so it is something I don't really care about :P
08:25 karolherbst: well...
08:25 karolherbst: MaximLevitsky: when did you join?
08:25 HdkR: If the Gen ISA changes that'll be fun to read about
08:26 MaximLevitsky: Last Tuesday
08:26 karolherbst: MaximLevitsky: ahh
08:26 karolherbst: team?
08:26 MaximLevitsky: Actually Monday
08:26 MaximLevitsky: kvm team
08:27 karolherbst: interesting
08:27 HdkR: That sounds like it'll be a team with unique challenges
08:27 MaximLevitsky: I will be working on improving support for virtualization of fast storage
08:27 karolherbst: ahh
08:27 MaximLevitsky: HdkR: that for sure.
08:28 karolherbst: yeah, that kind of sounds usefull
08:28 karolherbst: never really used kvm with storage backed by a SSD
08:28 karolherbst: or do you mean fast storage as in _super_ fast storage?
08:29 MaximLevitsky: karolherbst: more like super fast storage. the SSD stuff of course
08:29 karolherbst: like 10x nvme SSD Raid0 setups
08:29 HdkR: PCIe storage is great
08:29 karolherbst: yeah, multi queue + super fast
08:29 MaximLevitsky: I guess so, we focus on NVMe of course
08:29 karolherbst: ohh, I see
08:29 MaximLevitsky: karolherbst: exactly
08:30 karolherbst: some days ago somebody was complaining about getting "1 Mbit/s" as overall system read, I was like: yeah well, 100 IOPS, what do you expect on a HDD :D
08:31 karolherbst: anyway, that nvme stuff is already quite close on hitting the pcie v3 x4 bandwidth, which is kind of insane
08:32 HdkR: We just need PCIe v4/v5 to fix that issue ;)
08:32 HdkR: Sadly desktop x86 chips don't ship that yet
08:32 karolherbst: HdkR: no...
08:32 karolherbst: v4/v5 won't help
08:32 karolherbst: v4 is just double of speed
08:32 karolherbst: ...
08:33 karolherbst: you get nearly 4GB/s with v3, 8GB/s with v4
08:33 karolherbst: but the SSDs are already hitting the 4GB/s mark
08:33 HdkR: Isn't the upperend of NVMe SSDs hitting the upper ends on reads?
08:33 karolherbst: so, we get v4, and one year later we have 8GB/s SSDs
08:33 HdkR: Yep
08:34 karolherbst: I doubt that the M.2 interface will be able to use more than x4, maybe this could be somehow bumped with a new interface
08:34 karolherbst: x16 v4 gives nearly 32GB/s which is a bit harder to reach
08:34 HdkR: If you key it differently you might be able to fit x8 on to it
08:34 karolherbst: maybe
08:35 karolherbst: I think in the end we might get a completely new interface
08:35 karolherbst: which works more like RAM
08:35 karolherbst: and the CPU just states a top speed
08:35 karolherbst: but I guess this would require to many sw changes
08:35 HdkR: You mean like the Intel Optane Dimms but is actually storage rather than RAM? :)
08:36 MaximLevitsky: Will reboot my system and will debug some stuff. Bye for now!
08:36 karolherbst: HdkR: optane is storage
08:36 karolherbst: they are basically simply enterprise level SSDs
08:36 HdkR: https://www.anandtech.com/show/12828/intel-launches-optane-dimms-up-to-512gb-apache-pass-is-here
08:37 karolherbst: ahhh
08:37 HdkR: Optane in DDR4 form factor :D
08:37 karolherbst: yeah well
08:37 karolherbst: that might do
08:37 HdkR: Stick a boot drive in your DIMM slot
08:37 karolherbst: how fast are those?
08:38 karolherbst: ohh, not disclosed
08:38 karolherbst: boring
08:38 HdkR: No information on them yet
08:38 HdkR: yea
08:39 MaximLevitsky: I still don't know if the optane is a new kind of memory or it is DRAM + Flash backing + battery in the same package
08:39 MaximLevitsky: Any idea?
08:39 karolherbst: SSD
08:40 karolherbst: they just have some special memory chips
08:40 HdkR: XPoint is a type of persistent storage, kind of like NAND
08:40 karolherbst: and they aren't that great either
08:41 karolherbst: you already get consumer rate hardware with 500k IOPS
08:41 karolherbst: for much cheaper
08:41 HdkR: Doesn't have quite the performance numbers that Samsung gets, supposed to be quite a bit cheaper though
08:42 karolherbst: no, the optane ones are frigging expensive
08:42 karolherbst: 1.5 K$ for 375GB
08:42 karolherbst: I don't really know where they are better
08:46 MaximLevitsky: Thats funny...
08:46 MaximLevitsky: https://www.theregister.co.uk/2017/07/10/3d_nand_drives_to_overtake_optane/
08:46 MaximLevitsky: I like that 'floptane':-)
08:46 MaximLevitsky: But I hope that it does takes of
08:46 MaximLevitsky: *take off
08:50 karolherbst: why though?
08:50 karolherbst: overpriced SSDs?
08:53 HdkR: Oh wait, it was meant to cost more than traditional NAND but less than RAM. Right
08:56 karolherbst: HdkR: while being faster than NAND SSDs
08:56 karolherbst: but...
08:56 karolherbst: I doubt they will be able to hold up to that
08:56 karolherbst: maybe the DDR4 optanes will be much faster
08:57 HdkR: Seems like they have super fast latency, but throughput isn't winning anything with the current released products
08:57 karolherbst: well, IOPS aren't that high either
08:59 HdkR: Yea. wonder what the bottleneck is there.
08:59 karolherbst: HdkR: the dimm optanes have to be faster than 10GB/s to stay relevant
08:59 karolherbst: or well, to become relevant
09:00 HdkR: They have to compete with the highend PCIe SSDs
09:00 HdkR: not the M.2 drives stuck on a 4x lane configuration
09:00 HdkR: 8x and 16x things, their own products even
09:00 karolherbst: mhh, true
09:01 karolherbst: so the fastest are around 6.5 GB/s
09:01 karolherbst: kingston DCP1000
09:01 karolherbst: which are pcie x8 ones
09:01 karolherbst: not that expensive actually
09:01 karolherbst: 900€ for 800GB
09:02 karolherbst: 900k IOPS read
09:03 HdkR: I think there are some random non-consumer 16x SSDs around as well
09:03 HdkR: No idea if they are actually products since they are outside of the consumer space
09:04 karolherbst: HdkR: https://www8.hp.com/us/en/workstations/z-turbo-drive-g3.html
09:04 karolherbst: so 9 GB/s
09:05 HdkR: Hopefully the DIMM variants compete with that
09:05 karolherbst: anyway, that doesn't change the fact that intel has to reach at least 10 GB/s ;)
09:07 karolherbst: uhm wait
09:08 karolherbst: DDR4 dimms aren't that much faster actually
09:08 karolherbst: cpus support like 37.5 GB/s
09:08 HdkR: In dual channel right?
09:08 karolherbst: yes
09:09 karolherbst: well and I am sure you can go up to 70 GB/s in overclocking situations with XMP
09:09 HdkR: Who needs PCIe v5 when your bottlneck is RAM? :P
09:09 HdkR: bottleneck*
09:09 karolherbst: fastest are 4600 MHz
09:10 HdkR: Time to give CPUs 8 site HBM2
09:10 karolherbst: :D
09:10 karolherbst: there will be DDR5 like next year
09:11 HdkR: That will be nice
11:00 karolherbst: skeggsb, imirkin: any ideas? https://gist.github.com/karolherbst/b10b86747af9b21a73f27450359a8d7d
11:01 karolherbst: this is on a laptop with a gm204
11:02 karolherbst: display connected through an active HDMI -> DP adapter
11:08 karolherbst: I also hit that "disp: 0x00006341[0]: INIT_GENERIC_CONDITON: unknown 0x07" thing
11:08 karolherbst: mhh
11:08 karolherbst: it sometimes kind of seems to work
11:08 karolherbst: especially when the laptop display is turned on
11:09 karolherbst: also I know that the cable is a little broken, but it usually works quite good
11:27 karolherbst: and sometimes this happens: https://fpdl.vimeocdn.com/vimeo-prod-skyfire-std-us/01/996/11/279980046/1049345788.mp4?token=1531582025-0xbf96569990220febf23578c4c1e20089c74b0ba7
16:29 karolherbst: imirkin: mind reviewing those two patches? I would like to get all the cts fixes in see how the situation is on kepler later. https://patchwork.freedesktop.org/series/45307/ and https://patchwork.freedesktop.org/series/45313/
16:39 annadane: is there *any* way whatsoever to convince nvidia to open up their process, or do they still claim "because security reasons"
16:40 imirkin: annadane: of course there is
16:41 imirkin: just condition the purchase of a few $B of hardware on it. i'm sure it'll get their attention.
16:41 imirkin: karolherbst: i'll try to get to it in the next hour or two
16:42 karolherbst: annadane: patience
16:42 karolherbst: imirkin: nice, thanks!
16:42 karolherbst: annadane: there is "some" progress, we can just hope that progress will be faster in the future
16:43 karolherbst: annadane: of course being a customer wanting to spend 1B $ on GPUs and requiring open drivers might help
16:44 pendingchaos: imirkin: any idea what MEM_BARRIER does?
16:46 imirkin: flushes constbuffer caches
16:46 imirkin: 0x1011 is the "correct" value to put in there
16:46 imirkin: [but no, not _really_ sure...]
16:54 scientes: what is the cheapest card that does HEVC?
16:55 imirkin: scientes: your intel GPU should be able to do it, if it's new enough
16:55 scientes: i already have an old nvidia card that doesn't
16:55 scientes: this is a desktop
16:56 imirkin: nouveau doesn't support HEVC decoding in any case
16:56 scientes: i guess i can mix-and-match nouveau and ati?
16:56 scientes: oh ok
16:56 imirkin: i think some GM20x's support it, but not all? not sure, tbh.
16:56 imirkin: video decoding support stops at kepler for nouveau though
16:57 imirkin: i think AMD gpu's should support it well (the newer ones, obviously)
16:57 imirkin: and in general have a vastly better driver stack
17:02 scientes: i can run a nouveau card and amd-gpu at the same time?
17:04 imirkin: scientes: just not out of the same PCIe slot ;)
17:04 scientes: yeah i have two x16s
17:04 imirkin: they're just PCIe devices
17:04 imirkin: like any other
17:04 imirkin: one will be the primary for VGA and such
17:04 scientes: i just heard that fglrx and nvidia-binary conflicted before
17:05 imirkin: oh, that may be.
17:05 scientes: I plan on vga forward with kvm
17:05 imirkin: but nouveau + amdgpu should be no trouble
17:05 imirkin: well, kvm is later
17:05 imirkin: at boot time, for VGA access, the PCI bus can only forward those to a single device
17:06 imirkin: this tends to become your "primary" GPU, although the only thing that's special is that it receives VGA io port reads/writes
17:07 imirkin: (and probably some vga memory mapping stuff too)
21:37 pendingchaos: imirkin: am I correct in thinking https://github.com/mesa3d/mesa/blob/master/src/gallium/drivers/nouveau/nvc0/nvc0_state_validate.c#L583 is an optimization to avoid setting up the binding?
21:54 imirkin: no
21:54 imirkin: glUniform* sets up uniforms in the "default" uniform buffer
21:54 imirkin: on the mesa side, it's just kept in user memory
21:54 imirkin: and is passed to gallium as a "user" constbuf
21:55 imirkin: that means that on every draw we have to upload the data
21:55 imirkin: but also we keep track of the previous max size, since that's something that has to be associated with the binding
21:56 imirkin: and update it if it changes
21:58 pendingchaos: can you elaborate on why it needs to keep track of the previous max size?
21:58 imirkin: the length of the constbuf is part of the binding
21:59 imirkin: to avoid updating it every time, we keep track of it
22:00 pendingchaos: so doing "uniform_buffer_bound[s] < size" instead of just "true" is an optimization to avoid needlessly setting up the binding?
22:10 nyef: It's "if (!sufficient_space(...)) allocate_more_space(...);", isn't it?
22:11 pendingchaos: I think so
22:13 nyef: It's probably also one of those things that I'd paper over with a separate (possibly static inline) function.
22:14 nyef: Might even make it an "ensure" function, wrapping the entire thing, and putting the sufficient-space test as a guard-clause.
22:16 imirkin: pendingchaos: well, needlessly *changing* the binding