00:30 fdobridge: <C​ME> whee
00:30 fdobridge: <C​ME> https://cdn.discordapp.com/attachments/1034184951790305330/1062528935772033084/Bildschirmfoto_vom_2023-01-11_00-50-54.png
00:30 fdobridge: <C​ME> https://cdn.discordapp.com/attachments/1034184951790305330/1062528936174702702/Bildschirmfoto_vom_2023-01-11_01-02-03.png
00:37 fdobridge: <k​arolherbst🐧🦀> ohh wow.. do you own the talos principle?
00:37 fdobridge: <k​arolherbst🐧🦀> or maybe I just give it a shot over the weekend or something myself 😄
00:37 fdobridge: <C​ME> yeah it segfaults
00:37 fdobridge: <C​ME> both linux and wine
00:38 fdobridge: <k​arolherbst🐧🦀> mhh
00:38 fdobridge: <k​arolherbst🐧🦀> ohh.. probably because it's kepler
00:38 fdobridge: <k​arolherbst🐧🦀> oops
00:38 fdobridge: <C​ME> 750ti is maxwell v1
00:38 fdobridge: <k​arolherbst🐧🦀> ehh, right..
00:39 fdobridge: <k​arolherbst🐧🦀> but you can reclock, so that's the important part
00:39 fdobridge: <k​arolherbst🐧🦀> but you'll need a bunch of things
00:39 fdobridge: <k​arolherbst🐧🦀> https://gitlab.freedesktop.org/nouveau/mesa/-/merge_requests/118
00:39 fdobridge: <k​arolherbst🐧🦀> https://gitlab.freedesktop.org/nouveau/mesa/-/merge_requests/177
00:39 fdobridge: <C​ME> ah, i did only apply 177 so far
00:39 fdobridge: <k​arolherbst🐧🦀> yeah.. for games !118 will matter a lot more
00:41 fdobridge: <C​ME> nice, that fixed it
00:47 fdobridge: <k​arolherbst🐧🦀> cool
00:47 fdobridge: <k​arolherbst🐧🦀> how fast does it run on pstate 0xf?
00:47 fdobridge: <C​ME> hm, still dies after the croteam video
00:47 fdobridge: <k​arolherbst🐧🦀> and is it faster than GL?
00:47 fdobridge: <k​arolherbst🐧🦀> ehh 😢
00:47 fdobridge: <C​ME> but the video was running with 1sec per frame
00:47 fdobridge: <E​sdras Tarsis> Try running in windowed mode and low resolution
00:47 fdobridge: <C​ME> `[Mi Jan 11 01:46:50 2023] nouveau 0000:01:00.0: Talos[92332]: nv50cal_space: -16`
00:47 fdobridge: <k​arolherbst🐧🦀> `echo 0xf > /sys/kernel/debug/dri/0/pstate`
00:48 fdobridge: <k​arolherbst🐧🦀> mhh
00:48 fdobridge: <k​arolherbst🐧🦀> sounds bad
00:48 fdobridge: <k​arolherbst🐧🦀> sooo
00:48 fdobridge: <k​arolherbst🐧🦀> it's out of VRAM 🙂
00:48 fdobridge: <C​ME> yea already did that
00:48 fdobridge: <C​ME> how? since i can't reach the main menu
00:48 fdobridge: <k​arolherbst🐧🦀> @gfxstrand we might have to care more about VRAM consumption and actually have to figure out if we waste a ton of VRAM or something 😄
00:50 fdobridge: <C​ME> also ` 60,00% [vdso] [.] __vdso_clock_gettime` when it's running that slow
00:51 fdobridge: <k​arolherbst🐧🦀> yeah well... nouveau works great until you run into issues and then it just breaks ;')
00:51 fdobridge: <k​arolherbst🐧🦀> yeah well... nouveau works great until you run into issues and then it just breaks 🥲 (edited)
00:52 fdobridge: <k​arolherbst🐧🦀> anyway, you are out of VRAM and things are not working out that great in that case
00:52 fdobridge: <C​ME> ~~just like with rocm on amdgpu~~
00:57 fdobridge: <k​arolherbst🐧🦀> I know that nvk is doing some stupid things, the main question is... what exactly is the issue with talos here
00:57 fdobridge: <k​arolherbst🐧🦀> how much VRAM does your GPU have?
00:57 fdobridge: <C​ME> 2GB
00:57 fdobridge: <k​arolherbst🐧🦀> maybe I'll deal with those issues and see what I can figure out
01:03 fdobridge: <g​fxstrand> Yeah, 2GB isn't a lot. We should still be able to fit, probably.
01:04 fdobridge: <g​fxstrand> We may be allocating a bunch of stuff VRAM-only
01:06 fdobridge: <k​arolherbst🐧🦀> we probably want to bail if we know at submission time that we submit more memory than there is VRAM or something.. dunno
01:07 fdobridge: <k​arolherbst🐧🦀> could probably also start not submitting with all the buffers attached or something.. no idea what's the best approach here and how much pain it would be later on if we continue to do that
01:08 fdobridge: <g​fxstrand> We can't rely on splitting batches
01:08 airlied: later we won't be attaching any buffers since the api doesn't take any
01:08 fdobridge: <k​arolherbst🐧🦀> that's not what I meant
01:08 fdobridge: <k​arolherbst🐧🦀> ahh
01:08 fdobridge: <k​arolherbst🐧🦀> soo...
01:08 fdobridge: <k​arolherbst🐧🦀> how do you deal with oversubscribing? we just fail?
01:09 fdobridge: <k​arolherbst🐧🦀> or well.. I guess we'll fail on alloc then
01:09 fdobridge: <g​fxstrand> No
01:10 fdobridge: <E​sdras Tarsis> modifying the config file
01:11 fdobridge: <C​ME> ah, will try tomorrow
01:12 fdobridge: <g​fxstrand> @karolherbst🐧 What does BO_GART do?
01:13 fdobridge: <k​arolherbst🐧🦀> puts the memory into sysmem
01:13 fdobridge: <E​sdras Tarsis> When Talos doesn't recognize your GPU it uses the medium setting, so theoretically you can lower texture quality to lower VRAM usage
01:14 fdobridge: <g​fxstrand> @karolherbst🐧 Can we set GART and LOCAL at the same time?
01:14 fdobridge: <k​arolherbst🐧🦀> well.. hardware says yes, driver says no
01:14 fdobridge: <k​arolherbst🐧🦀> and without resizable BAR it's quite useless
01:14 fdobridge: <k​arolherbst🐧🦀> you see this 256MB area nvidia advertises as.. ehhh.. what were the flags again?
01:15 fdobridge: <k​arolherbst🐧🦀> that's GART | LOCAL stuff
01:15 fdobridge: <g​fxstrand> I want something that's VRAM but I promise never to map it so it's ok to put in system RAM if we run out of space.
01:15 fdobridge: <k​arolherbst🐧🦀> ahh yes
01:15 fdobridge: <k​arolherbst🐧🦀> soo
01:16 fdobridge: <k​arolherbst🐧🦀> the way you do it now is that you don't add it to the list of bos when submitting your job and then nouveau pages it out into system memory
01:16 fdobridge: <k​arolherbst🐧🦀> but it's only doing so for unused memory
01:16 fdobridge: <k​arolherbst🐧🦀> there are also buffers where the GPU doesn't care if it's in system memory or VRAM
01:16 fdobridge: <k​arolherbst🐧🦀> and either way works
01:17 fdobridge: <g​fxstrand> How do I specify that?
01:17 fdobridge: <k​arolherbst🐧🦀> so what I think I'd like to see is, that we can mark certain buffers as "it should be in VRAM,but if it has to be, you can also page it out into system memory"
01:17 fdobridge: <k​arolherbst🐧🦀> you don't
01:17 fdobridge: <g​fxstrand> Where it accesses from system memory across PCIe if needed
01:17 fdobridge: <g​fxstrand> Yeah, that's a problem.
01:17 fdobridge: <k​arolherbst🐧🦀> I know
01:17 fdobridge: <k​arolherbst🐧🦀> it's just not supported
01:17 fdobridge: <g​fxstrand> That's not a problem we can fix in NVK
01:17 fdobridge: <g​fxstrand> Not really
01:17 fdobridge: <k​arolherbst🐧🦀> correct
01:18 fdobridge: <k​arolherbst🐧🦀> we just need two things really from the kernel driver here
01:19 fdobridge: <k​arolherbst🐧🦀> 1. mappable VRAM (through PCIe BAR + resizable BAR so it's not limited to 256MB)
01:19 fdobridge: <k​arolherbst🐧🦀> 2. marking certain buffers as allowed to be paged out into sys RAM on high memory pressure, but still as available to the GPU for jobs
01:19 fdobridge: <k​arolherbst🐧🦀> 1. mappable and _readable_ VRAM (through PCIe BAR + resizable BAR so it's not limited to 256MB)
01:19 fdobridge: <k​arolherbst🐧🦀> 2. marking certain buffers as allowed to be paged out into sys RAM on high memory pressure, but still as available to the GPU for jobs (edited)
01:21 fdobridge: <k​arolherbst🐧🦀> but I suspect we are just not super careful about memory allocations or something ... dunno... maybe I spend some time figuring out if we leak memory or just allocate things we don't strictly need...
03:48 fdobridge: <g​fxstrand> It's possible we're leaking. Shouldn't be too hard to check.
04:16 fdobridge: <g​fxstrand> Doing a BO leak check run now
04:19 fdobridge: <g​fxstrand> Doesn't look like we're leaking but I'll let the run finish.
04:25 fdobridge: <g​fxstrand> Yeah, half-way through a run with no significant crashes on `assert(dev->bo_cnt == 0` in `nouveau_ws_device_destroy()`. I don't think we're leaking.
08:28 OftenTimeConsuming: RSpliet: >nah, I upgraded to AMD. Sorry, not sorry You'd be sorry having to load up proprietary software before the card works.
14:43 fdobridge: <g​fxstrand> Yup, no leaks
15:53 fdobridge: <k​arolherbst🐧🦀> yeah well.. annoying 😢
15:54 fdobridge: <k​arolherbst🐧🦀> is nvk doing anything where we might allocate more memory than we actually need?
15:54 fdobridge: <k​arolherbst🐧🦀> but.... mhh
15:55 fdobridge: <k​arolherbst🐧🦀> @gfxstrand do you think we should track the reason a bo was created? like a string just indicating where it's coming from (or enum value or _something_) and then if we try to submit a batch >= vram_size we can dump the info and easily tell why stuff got allocated the most or something?
15:57 fdobridge: <k​arolherbst🐧🦀> though I can see why that's harder to do in vulkan than e.g. gl
15:57 fdobridge: <k​arolherbst🐧🦀> and might not even help
16:07 fdobridge: <g​fxstrand> I guess we could.
16:08 fdobridge: <g​fxstrand> I'm really not surprised that you'd run out of memory on a 2GB card, though. We really should focus on fixing the kernel.
16:08 fdobridge: <g​fxstrand> I mean, yeah, we can debug why this game is burning memory but lots of games blow past 2GB.
16:21 fdobridge: <C​ME> forsaken also hits `[ 1620.025931] nouveau 0000:01:00.0: ForsakenEx[12492]: nv50cal_space: -16` in the main menu, with the same settings the game only eats 146MB vram on my 1060
16:24 fdobridge: <k​arolherbst🐧🦀> yeah.. but that game doesn't really need much
16:24 fdobridge: <k​arolherbst🐧🦀> min spec is like 1 GB VRAM
16:25 fdobridge: <g​fxstrand> We could make NVK refuse to allocate more VRAM than exists on the card and see if that does anything.
16:25 fdobridge: <k​arolherbst🐧🦀> mhh
16:25 fdobridge: <k​arolherbst🐧🦀> I can try that out on the weekend, I own the game and I own enough low spec cards 😄
16:26 fdobridge: <k​arolherbst🐧🦀> but yeah.. I think refusing to allocate is probably a good idea. We might also want to check if our accounting is in order. Not that we run out of VRAM if the app things only 500MB are in use or something
16:26 fdobridge: <k​arolherbst🐧🦀> but yeah.. I think refusing to allocate is probably a good idea. We might also want to check if our accounting is in order. Not that we run out of VRAM if the app thinks only 500MB are in use or something (edited)
16:35 fdobridge: <g​fxstrand> I wonder if we're actually running into resizable BAR issues.
16:35 fdobridge: <g​fxstrand> It may not be that we're running out of VRAM, just CPU mappable VRAM.
16:35 fdobridge: <g​fxstrand> That's a much smaller resource
16:35 fdobridge: <g​fxstrand> Or did you tell me that nouveau doesn't support that at all?
17:11 fdobridge: <k​arolherbst🐧🦀> we can't read from it
17:12 fdobridge: <k​arolherbst🐧🦀> unless the driver paged it out to system memory
17:12 fdobridge: <k​arolherbst🐧🦀> but we map bos to write into them and that seems to work just fine
17:12 fdobridge: <k​arolherbst🐧🦀> but we map bos to write to them and that seems to work just fine (edited)
17:33 fdobridge: <g​fxstrand> Ok, for stuff like descriptor tables, that's fine. For anything exposed to the client, not so much.
17:33 fdobridge: <g​fxstrand> The batch stuff also isn't currently guaranteed read-free.
17:34 fdobridge: <g​fxstrand> descriptor tables and shader programs are, though.
17:39 fdobridge: <k​arolherbst🐧🦀> sure, but local mem isn't mapable, so that's fine
17:45 fdobridge: <g​fxstrand> We want to make some of it mappable eventually
17:45 fdobridge: <g​fxstrand> If we can
17:45 fdobridge: <g​fxstrand> But we don't need to today
17:45 fdobridge: <g​fxstrand> @airlied where do I find a kernel branch with the new uAPI?
17:46 fdobridge: <k​arolherbst🐧🦀> the
17:51 fdobridge: <k​arolherbst🐧🦀> yeah.. we really want to advertise VRAM like nvidia does. They just add a local + mappable 256MB memory type, but...
17:51 fdobridge: <k​arolherbst🐧🦀> doesn't matter all that much
18:13 fdobridge: <g​fxstrand> Oh, yes it matters
18:13 fdobridge: <g​fxstrand> That's like a 20% perf bump for a bunch of DXVK stuff.
18:15 fdobridge: <k​arolherbst🐧🦀> I see
18:15 fdobridge: <k​arolherbst🐧🦀> I guess that's for very small reads and stuff?
18:15 fdobridge: <g​fxstrand> vertex etc. upload.
18:15 fdobridge: <g​fxstrand> Any stream upload, really.
18:16 fdobridge: <g​fxstrand> WC map, write directly to VRAM, do the thing.
18:16 fdobridge: <k​arolherbst🐧🦀> mhh
18:16 fdobridge: <k​arolherbst🐧🦀> yeah.. I guess that's the data which all fits within 256MB
18:17 fdobridge: <k​arolherbst🐧🦀> though if we add it, we might want to support resizable BAR while at it anyway
18:17 fdobridge: <k​arolherbst🐧🦀> I suspect nobody was looking into it for now, not sure if it's on @airlied radar or if we have to ping Ben about it
18:20 fdobridge: <E​sdras Tarsis> vkcube crashed my xorg session :ferris_happy:
18:44 fdobridge: <g​fxstrand> 😬
19:05 fdobridge: <g​fxstrand> Does pre-turning have some weird render target size alignment or something? 🤔
19:13 fdobridge: <a​irlied> https://gitlab.freedesktop.org/nouvelles/kernel/-/tree/new-uapi-drm-next
19:14 fdobridge: <k​arolherbst🐧🦀> probably, maybe it's page aligned, or 0x100 like a lot of other stuff
19:15 airlied: jekstrand: my new uapi branch has some alignment changes
19:16 fdobridge: <g​fxstrand> All my addresses look mostly fine
19:17 fdobridge: <g​fxstrand> They're aligned to like 2^20
20:07 fdobridge: <g​fxstrand> Oh, I know what's going on. 😅
20:07 fdobridge: <g​fxstrand> maybe
20:13 fdobridge: <g​fxstrand> Yup. We were allocating shadow BOs for linear images on Maxwell.
20:13 fdobridge: <g​fxstrand> That should fix a bunch of tests.
20:13 fdobridge: <g​fxstrand> Can't wait until I can delete the shadow BO stuff.
20:35 fdobridge: <k​arolherbst🐧🦀> uhh
20:35 fdobridge: <k​arolherbst🐧🦀> we need the new UAPI to delete those BOs?
20:56 fdobridge: <C​ME> hmm, tried launching forsaken for the 3rd time and `[22707.909287] nouveau 0000:01:00.0: Xwayland[3535]: nv50cal_space: -16`
20:57 fdobridge: <C​ME> now the kernel oopsed and gnome is just a corrupted mess 😄
21:21 fdobridge: <g​fxstrand> Yup. Anything with a non-zero PTE kind needs to be bound sparse.
21:21 fdobridge: <g​fxstrand> ```
21:21 fdobridge: <g​fxstrand> Pass: 218886, Fail: 9757, Crash: 2234, Warn: 4, Skip: 1328585, Flake: 1097, Duration: 36:21
21:21 fdobridge: <g​fxstrand> ```
21:21 fdobridge: <g​fxstrand> That's a bit better. 😄
21:21 fdobridge: <k​arolherbst🐧🦀> heh
21:44 fdobridge: <a​irlied> @gfxstrand not sure we have that requirement well dealt with in the kernel interface, maybe it just works
21:46 fdobridge: <g​fxstrand> Which requirement?
21:47 fdobridge: <a​irlied> non-zero PTE kind bound as sparse
21:48 fdobridge: <a​irlied> would be good to try and wire that up on the new uapi
21:48 fdobridge: <g​fxstrand> Yeah, we should.
21:48 fdobridge: <g​fxstrand> Really the only thing the uAPI needs is support for specifying the PTE kind in the binding.
21:49 fdobridge: <g​fxstrand> But we should get rid of the shadow BOs and do it "properly" in your branch and prove it out.
22:57 airlied: Pass: 598536, Fail: 966, Crash: 2, Warn: 11, Skip: 1313606, Flake: 1, Duration: 4:09:30, Remaining: 0
22:57 airlied: on the new uapi
22:58 airlied: on my tu104
23:04 airlied: oh maybe that was lvp :-P
23:04 airlied: ah yes lots of traps now
23:34 fdobridge: <g​fxstrand> Ok, so blit (draw) to 3D works.... just on every 4th slice. WTF?
23:50 fdobridge: <k​arolherbst🐧🦀> eh
23:50 fdobridge: <m​henning> is it in color? mixing up planar and interleaved rgba? or something?
23:51 fdobridge: <m​henning> (taking shots in the dark here)
23:51 fdobridge: <g​fxstrand> It's a normal R8G8B8A8 3D image.
23:52 fdobridge: <g​fxstrand> Slices 0, 4, 8, and 12, all the others are wrong (it's got 16 total)
23:52 fdobridge: <g​fxstrand> where by "wrong" I mean nothing rendered at all
23:52 airlied: is 4 got 4 or has 4 got 1?
23:53 fdobridge: <g​fxstrand> 4 has 4
23:53 fdobridge: <g​fxstrand> I thought of that. 😅