alyssa changed the topic of #panfrost to: Panfrost - FLOSS Mali Midgard & Bifrost - Logs https://freenode.irclog.whitequark.org/panfrost - <daniels> avoiding X is a huge feature
stikonas has quit [Ping timeout: 252 seconds]
<alyssa> jernej: Yes
<alyssa> as urjaman said, not exposed yet.
<alyssa> I swear linking my code is taking way longer than it used
<anarsoul> new compiler?
<anarsoul> or rather linker
<HdkR> Time to switch to LLD
<alyssa> Dunno
* alyssa tries to get fp16 RA working well
<alyssa> Just so I can make things are sane before landing LCRA
<alyssa> Spoiler alert: they'r enot.
<alyssa> (LCRA itself is fine. Other Midgard stuff, less so.)
vstehle has quit [Ping timeout: 240 seconds]
<alyssa> Mostly swizzle packing silliness
<endrift> So now that I have a computer with panfrost on it
<endrift> is there anything I can do to help?
<endrift> ah! I knew there must be an issue tracker somewhere
<HdkR> endrift: Run your favourite applications and make it run without issues :P
<endrift> I'm not even sure where to start tbh
<endrift> guess I should see if mGBA works :P
<endrift> I'm noticing I have GLES 2 only, I'm assuming that's because the driver just doesn't support 3 yet
<HdkR> correct
<endrift> hopefully that will change at some point :)
<endrift> but I understand there's not as many people working on it as the official driver had
<HdkR> Force ES 3.0 and fix things that fail? :P
<endrift> this issue tracker seems to mostly be compiler issues
<anarsoul> that would be *much* faster if we had specs for hw
<endrift> which is unfortunately not my area expertise :(
<anarsoul> endrift: not mine either, but I try :)
<HdkR> Basically I need to open source my emulator so endrift will work on it and get better at compilers :D
<endrift> I used to have a copy of the dragon book but it got lost in the mail
<endrift> although I hear the dragon book is really antiquated at this point
<anarsoul> endrift: I believe compiler is in decent state, so start with some simple tasks?
<endrift> I'll look into it when I have some time. Which is not actually today
<anarsoul> :)
<anarsoul> yeah, Tuesday
<endrift> I'm partway through moving so I'm kind of exhausted
davidlt has joined #panfrost
<HdkR> :)
megi has quit [Ping timeout: 265 seconds]
Thra11_ has quit [Ping timeout: 265 seconds]
vstehle has joined #panfrost
Thra11_ has joined #panfrost
<tomeu> alyssa: that worked, thanks!
<tomeu> alyssa: one more: http://paste.debian.net/1116008/
<tomeu> this is with dEQP-GLES2.functional.fbo.render.color.mix_tex2d_rgb on t720
_whitelogger has joined #panfrost
guillaume_g has joined #panfrost
guillaume_g has quit [Client Quit]
fysa has joined #panfrost
fysa has quit [Remote host closed the connection]
guillaume_g has joined #panfrost
yann has quit [Ping timeout: 240 seconds]
pH5 has joined #panfrost
jernej has quit [Quit: Free ZNC ~ Powered by LunarBNC: https://LunarBNC.net]
jernej has joined #panfrost
fysa has joined #panfrost
yann has joined #panfrost
<bbrezillon> daniels: I'm currently testing partial-update+enlightenment, and buffer_age() returns me 1 most of the time, and sometimes 4 or 5 ?!
fysa has quit [Ping timeout: 246 seconds]
<bbrezillon> note that it's using the DRI3 implementation (loader_dri3_query_buffer_age())
<bbrezillon> any idea what could be causing that?
<bbrezillon> looking at the back buffer address, I seem to have 2 buffers
<bbrezillon> so I'd expect an age of 2 (except at the beginning)
stikonas has joined #panfrost
stikonas has quit [Ping timeout: 252 seconds]
maccraft123 has joined #panfrost
fysa has joined #panfrost
fysa has quit [Ping timeout: 265 seconds]
<daniels> bbrezillon: 4 or 5 can happen when the app doesn't keep constant frame rate so bounces between double and triple buffering ... but yeah if you only ever have 2 allocated then that's obviously wrong
maccraft123 has quit [Quit: WeeChat 2.6]
karolherbst has quit [Ping timeout: 265 seconds]
maccraft123 has joined #panfrost
rhyskidd has joined #panfrost
maccraft123 has quit [Quit: WeeChat 2.6]
sphalerite has quit [Ping timeout: 264 seconds]
karolherbst has joined #panfrost
sphalerite has joined #panfrost
karolherbst has quit [Quit: duh 🐧]
karolherbst has joined #panfrost
fysa has joined #panfrost
maccraft123 has joined #panfrost
fysa has quit [Ping timeout: 268 seconds]
<dhewg> tomeu: with sw decoding some videos won't play back on t720
<dhewg> im not seeing any relevant debug output so far
<dhewg> any idea what that is about? missing support for some color spaces maybe?
<dhewg> on one file `mpv --opengl-rectangle-textures` errors out with "no matching function for call to `texture2D(sampler2DRect, vec2)'; candidates are: vec4 texture2D(sampler2D, vec2)..."
<bbrezillon> daniels: looks like we receive XCB_PRESENT_EVENT_IDLE_NOTIFY before querying the new back buffer, and the implementation decides to reuse the same buffer, hence the age=1 here
<bbrezillon> (I mean, the buffer is considered idle, and the implementation can reuse it immediately)
maccraft123 has quit [Ping timeout: 268 seconds]
<bbrezillon> the problem is, the 2nd buffer, which not used most of the time keeps getting older and older
maccraft has joined #panfrost
megi has joined #panfrost
maccraft has quit [Quit: WeeChat 2.6]
<daniels> right, that makes sense - it's optimised for the steady state
<bbrezillon> so you reckon it should stay like that
<bbrezillon> I made this change http://code.bulix.org/4oixuj-952706 and now I have a buffer age of 2
<bbrezillon> but the partial-update bug is even more visible now :-(
karolherbst has quit [Quit: duh 🐧]
karolherbst has joined #panfrost
fysa has joined #panfrost
<tomeu> dhewg: that doesn't seem t720-specific
<tomeu> maybe we miss texture rectangle support?
<dhewg> i just tried --opengl-rectangle-textures for testing purposes
<dhewg> there's no error without, but still just a black screen
<dhewg> otoh --opengl-rectangle-textures worked on a file which played back fine without
fysa has quit [Ping timeout: 240 seconds]
<alyssa> endrift: Dragonbook IIRC is very focused on front-end, less so on backend
<alyssa> IIRC little/nothing on instruction scheduling, which is one of the most complicated parts of a modern compiler
<alyssa> tomeu: Oh, I bet I know what happened with T720
<alyssa> erm
<alyssa> dEQP-GLES2.functional.fbo.render.color.mix_tex2d_rgb
<alyssa> We're reading two texture registers but the work register count is one
<alyssa> I bet T720 wants a unified work_register_count
<tomeu> ah, that would make sense
<alyssa> i.e. we should set work_register_count on T720 to `MAX2(work_register_count, 2)` so we can always grab texture registers
<tomeu> I have seen all the time a work_count of 2 when we expected 1
<alyssa> 1/2/3/4 work registers all correspond to the same thread count so that won't affect perf.
<alyssa> Might give a try with just that MAX2 added to pan_assemble.c
<alyssa> [ And then if that's it, update pandecode to validate that ]
<alyssa> tomeu: Okay here's a bigger WHAT?
<alyssa> The uh
<alyssa> trace you sent me
<alyssa> is using r26/27 for texture coordinate and r0 for texture output
<alyssa> I was under the distinct impression that was only for vertex shaders.
<alyssa> What gives?
<tomeu> I guess for the T720 they just wanted to save silicon at all costs
<alyssa> Is there a flag that controls this?
<alyssa> Does T720 use the other texturing form and we just never noticed? How's that possible?
<alyssa> tomeu: Do *any* textures *ever* work on T720?
<alyssa> I think they must, somebody said Kodi is fine
<alyssa> Uhm.
<alyssa> What am I missing here.
<alyssa> "save silicon at all costs" Then why.. support both....?
<tomeu> I'm afraid they don't support both in all situations :/
<alyssa> Evidently so.
<alyssa> Guess we have the easy peasy job of figuring out which situations are which, huh?
<alyssa> Given dEQP-GLES2.functional.shaders.random.texture.fragment.* is failing I mean that would
<alyssa> oh dear.
<alyssa> i think I might have an idea what's up.
<alyssa> and i do not like.
megi has quit [Quit: WeeChat 2.6]
<tomeu> alyssa: btw, we got 8 regressions less by setting work_groups to a minimum of 2
<tomeu> let me check which
<tomeu> alyssa: yeah, all the dEQP-GLES2.functional.fbo.render.color.mix_* tests now pass
<alyssa> tomeu: Woo.
<alyssa> dhewg: Timely, that's what tomeu and I are fixing rn :)
<tomeu> dhewg: I would say that there's no point in testing t720 atm
<dhewg> heh, that bad?
<alyssa> Unfortunately, give it a few weeks though ;)
<dhewg> sure, lemme know if i should test some patches
<alyssa> :+1:
fysa has joined #panfrost
fysa has quit [Ping timeout: 240 seconds]
<alyssa> Let's land LCRA today, y'all.
* tomeu approves
<tomeu> dhewg: I don't have much use for bug reports for t720, because I'm 100% focused on fixing the remaining deqp regressions, compared with t760
<alyssa> (And most bugs in apps corresponds to deqp fails)
<tomeu> right
<tomeu> dhewg: but in january I will change gears and would like to hear about stuff that is still broken
<dhewg> sounds good! i was just suprised how fast and painless i could kodi running on mesa/t720, so it felt like its "already there" ;)
<alyssa> dhewg: Tomeu's been doing good work on T720!
<dhewg> didnt try to imply otherwise!
maccraft123 has joined #panfrost
maccraft123 has quit [Client Quit]
maccraft123 has joined #panfrost
<tomeu> the tracing infrastructure is just awesome to debug problems with the cmdstream
<alyssa> I'm glad to hear that
<alyssa> I could never get the hang of it, and I wrote the dang thing.
<tomeu> and for the compiler problems, one just tells alyssa and has a fix in the morning
<alyssa> On that note
<alyssa> tomeu: Try branch t720-vtx-v3
<tomeu> so there's no excuse for anybody to not fix their midgard GPUs :)
<alyssa> -v3 is rather aggressive ..
<alyssa> First of all it plays games with RA to fix the spilling on uniform_api.* so that much should maybe be fixed but I didn't really test
<alyssa> More so I set it up to use the vertex texturing code path *everywhere* on t720
<alyssa> I.. don't know if that's correct. But you will either see a ton of tests pass or a ton of tests regress.
<alyssa> Either way we learn something :)
<alyssa> (lmk how it goes)
<tomeu> ok, have rebased and pushed, but there seems to be a lot of contention atm
<alyssa> gracia
<tomeu> will do some testing locally
sphalerite has quit [Quit: WeeChat 2.6]
sphalerite has joined #panfrost
<daniels> tomeu: yeah, gst seems to be hitting the runners hard today
<tomeu> ack
<tomeu> alyssa: from the testing I've done locally, textures continue similarly broken, but I don't hit the spilling assertion any more
raster has joined #panfrost
<tomeu> alyssa: the CI job finished, there have been no changes in the list of failures
fysa has joined #panfrost
<tomeu> alyssa: from what I can see, texturing from the vertex shader is still broken in the uniform_api tests: https://people.collabora.com/~tomeu/TestResults.xml
fysa has quit [Ping timeout: 265 seconds]
<bbrezillon> raster: I'm debugging partial-update+enlightenment, and I noticed that keeping the damage extend + forcing the damage box to 0.0->0.0 solves the problem
<bbrezillon> raster: are you sure you update the whole region covered by the damage rects?
<raster> bbrezillon: really sure. it's the same logic for sw
<raster> and our update buffers are malloced so if we didnt render parts of those it'd be junk
<raster> or they are recycles shm buffers from a shm pool
<raster> (in sw)
<raster> both sw and gl share the same logic for update region tracking etc.
<raster> and what do you mean by forxing the dmg box?
<bbrezillon> raster: ^
<raster> bbrezillon: waaait. that just kills off the bounding box mesa is tracking
<raster> that smells wrong unless the bbox there is miscalculated....
<alyssa> tomeu: Beep.
<alyssa> I'm ... not sure how to interpret that result.
<bbrezillon> raster: nope, the bounding box is stored in damage.extent
<bbrezillon> damage.box is the biggest damage rect passed by the app
<bbrezillon> it's here to avoid reloading the whole bounding box if we can
<tomeu> daniels: could you please add the lava-minnowboard-turbot-E3826 tag to the lava runner?
<tomeu> alyssa: no change in the failures list?
<alyssa> tomeu: Right.
<bbrezillon> raster: (assuming I understand what you mean by bounding box)
<alyssa> tomeu: I would have expected at least some tests to change, in either direction.
<tomeu> maybe we have been using llvmpipe in CI all the time? :p
<alyssa> oh wait.
<alyssa> derp.
<raster> bbrezillon: but you set damage.min[xy]/max[xy] to 0 right after it was calculated from the biggest...
<raster> ?
<bbrezillon> raster: that's not the solution, just a test
<raster> ok
<raster> but that implies the bbox calc was wrong
<alyssa> tomeu: cherry-pick the latest commit on t720-vtx-v3 I didn't do the change I thought I did whoops
<raster> i cant rememebr but wasnt 0,0,0,0 == no min/max?
<raster> ie reset it to nothing?
<raster> i might be mixing this up with other code...
<daniels> tomeu: done
<bbrezillon> damage.box == 0,0,0,0 and damage.extent = x1,y1,x2,y2 means you reload the whole x1,y1,x2,y2 region
<bbrezillon> raster: ^
<bbrezillon> and then glDraws appear on top
<bbrezillon> I checked the buffer age and resources used for each set_damage/draw/flush and they seem to be correct
<bbrezillon> so I'm looking at other things that could explain those corruptions now
<tomeu> daniels: thanks!
<daniels> np
<raster> bbrezillon: yeah. it essentially disables the box so it loads everythgin rather than everything EXCEPT that rect... right?
<bbrezillon> yep
<raster> so the box geom is invalid (as a result of the above)
<raster> why it's invalid i a good q...
<raster> i already printf'd a lot of boxes/rects going into egl.... and they seemed right
<raster> but can do that again... follow the breadcrumbs
<raster> i'm sure you printf'd the rects coming in at the gl interface point?
<bbrezillon> ^ that might be a problem, but I only see one flush per swap right now
<raster> bbrezillon: that'd be correct
<bbrezillon> clearly, the KHR_partial_update() spec states that the damage region stays active until the next swap
<raster> the output buffer flush in gl just fliushes all the rendering done so far to screen
<raster> ie - swap
<bbrezillon> which means that any explicit flush that happen between 2 swap will not reset the damage region
<raster> yup
<raster> though what are u testing? x or wayland?
<bbrezillon> yes, but if you add draws after the flush, the implem doesn't know it has to reload the region that was previously drawn
<bbrezillon> X
<raster> aaah i was testing wl (gl_drm)
<bbrezillon> didn't manage to start gl_drm
<raster> just running e in a tty will run in wl mode
<raster> nothing special to enable
<raster> :)
<raster> well if e and efl are built with wl and drm support...
<bbrezillon> I did use the same PKGBUILD options
<bbrezillon> anyway, should work with X too, right?
<raster> those all enable that so u're ok
<bbrezillon> and seem to have pretty much the same black tiles you had the other day
<bbrezillon> so it's probably not related to X vs WL_DRM
<raster> glsym_evas_gl_symbols() will be called before rendering after we get buffer age and use that plus update regions to calculate render regions. it should be called just once per fream at the start for rendering so thats where the input comes from
<bbrezillon> I added traces to eng_output_redraws_next_update_get() to understand how the damage rects were built
<bbrezillon> I always end up with a single rect
<raster> aaah that'll be during iterating over the rects rendering each
<bbrezillon> yes, that's the part I was looking at right now
<raster> so that'll be after setting them up with the setdamageregion()
<bbrezillon> yes
<raster> you will end up with multiple rects if you have the right situations
<raster> theres a bunch of fuzzy logic that tries to merge rects near eachother, round them up to 16x16 tile regions, and try limit the number of them as well
<bbrezillon> would need to track the area cover by each draw happening between the set_damage_region() and swap()
<raster> so it'll eventually expand them as bounding regions betwen multipel smaller input render regions just to do some tradeoff of # of render passes vs benefit to rendering less per pass :)
<bbrezillon> as long as everything is re-rendered inside the damage extent and no explicit flush come in before the swap we should be good
<bbrezillon> *comes
<tomeu> dhewg: you may want to check out this branch: https://gitlab.freedesktop.org/tomeu/mesa/commits/lava-ci-t720-III
<raster> that is exactly how it should be working
<raster> if we flushed before we had rendered all the regions we'd miss out entire update regions
<bbrezillon> raster: hm, so I reverted the damage.box = 0 and added an explicit damage-reset after each flush
<bbrezillon> and it work :-(
<bbrezillon> works*
<tomeu> alyssa: the cube now looks textured in glmark
<raster> bbrezillon: the damage region should automatically be reset after every swap ... right?
<raster> by mesa...
<bbrezillon> raster: swap yes, not flush
<raster> what - which flush
<raster> this is the evas_outbuf_flush()?
<raster> or another?
<bbrezillon> that probably means we have a glFlush() (or something calling a flush internally)
<bbrezillon> I don't know yet
<raster> because the outptuf flush is the swap thing :)
<raster> (also possibly passing damage regcts with tht swap and setting swap interval etc.)
<bbrezillon> you mean glsym_evas_gl_common_context_flush() ?
<raster> oh no
<raster> that is different
<raster> that flush pushes out pending triangle arrays we accumulted in the core common renderer
<raster> so basically a gldraqwarrays()
<bbrezillon> that's the one called from eng_outbuf_push_updated_region()
<raster> it may issu emultiple drawarrays
<bbrezillon> ok, so no flush
<bbrezillon> I mean, no glFlush()
<raster> the common rendere doesnt actually "draw" when u ask. it accumulates trinalge sin up to 128 separate triangle buffers
<bbrezillon> (so many things using the term flush :))
<raster> each tri buffer is for a specific texture id, shader program, blend mode etc.
<raster> so this allows us to issue fewer drawarrays by merging lots of draws that share the same context info
<raster> the common flush forces alll the pending tri buffers to be pushed out and cleared
<raster> and yeah
<raster> so manhy flushes
maccraft123 has quit [Quit: WeeChat 2.6]
<raster> we actually dont call glFlush()
maccraft123 has joined #panfrost
<raster> well there is code to call it but ONLY if the app is using out explicit exposing of the opengl-es api
<raster> e will not be doing that when rendering
<raster> it's highly rare to use this
<raster> (as it means doing immediate mode rendering)
<dhewg> tomeu: nice, that was fast
<dhewg> and i think we have a winner, i see videos playing back using egl that don't with mesa master
raster has quit [Quit: Gettin' stinky!]
<tomeu> yeah, it's starting to look pretty good
<dhewg> indeed, nice work
<dhewg> i'll play around some more and try to break it
Thra11_ has quit [Ping timeout: 265 seconds]
<dhewg> nope, everything that didn't play before now plays fine. with either mpv or kodi
<tomeu> alyssa: I'm quite surprised to find that, when running locally the 222 tests that fail on CI, only 80 of them fail
<tomeu> same mesa commit
Thra11_ has joined #panfrost
pH5 has quit [Quit: bye]
raster has joined #panfrost
raster has quit [Client Quit]
gcl has quit [Ping timeout: 240 seconds]
gcl has joined #panfrost
maccraft123 has quit [Quit: WeeChat 2.6]
fysa has joined #panfrost
<robmur01> tomeu: apparently the distinction between "older midgard" and "t720" is still a bit blurred - t620 becomes super-broken with that branch :(
maccraft123 has joined #panfrost
yann has quit [Ping timeout: 240 seconds]
megi has joined #panfrost
pH5 has joined #panfrost
karolherbst has quit [Ping timeout: 268 seconds]
jolan has quit [Quit: leaving]
pH5 has quit [Read error: Connection reset by peer]
jolan has joined #panfrost
fysa has quit [Ping timeout: 265 seconds]
pH5 has joined #panfrost
<alyssa> robmur01: Good to know, thank you for testing
<alyssa> tomeu: "the cube now looks textured in glmark" Ey!
<robmur01> the cube does indeed now appear textured on my t720 too; it just no longer appears at all on my t620 :P
<alyssa> :P
<alyssa> I can finegrain
yann has joined #panfrost
robmur01 has quit [Ping timeout: 268 seconds]
robmur01 has joined #panfrost
karolherbst has joined #panfrost
fysa has joined #panfrost
fysa has quit [Read error: Connection reset by peer]
maccraft123 has quit [Quit: WeeChat 2.6]
maccraft123 has joined #panfrost
maccraft123 has quit [Quit: WeeChat 2.6]
robmur01 has quit [Remote host closed the connection]
robmur01 has joined #panfrost
guillaume_g has quit [Quit: Konversation terminated!]
stikonas has joined #panfrost
maccraft123 has joined #panfrost
BenG83 has joined #panfrost
NeuroScr has joined #panfrost
maccraft123 has quit [Quit: WeeChat 2.6]
maccraft123 has joined #panfrost
maccraft123 has quit [Client Quit]
* alyssa time to clean up giant set of branches
<alyssa> now that LCRA is merged
<anarsoul> yay
<anarsoul> :)
maccraft123 has joined #panfrost
<alyssa> Yay indeed :)
<alyssa> unfortunatley I can't just delete everything ... lot of my forgotten branches I have here do contain good code that I forgot about due to task switching
<alyssa> so I'm going through and cherry-picking
<Lyude> i feel that
<Lyude> i have so many branches for various features and stuff that are mostly done, but I haven't been able to finish up because i've been way too preoccupied with other stuf
<Lyude> (not on panfrost, just in general with the projects I work on)
<HdkR> The last couple percent towards finishing a branch of work is always the most work :P
<Lyude> for sure
<alyssa> Sigh
<alyssa> With that, time to rebase my SSBO/OpenCL series now that LCRA landed and see where we're at
<alyssa> ..of course, most of mesa is now recompiling...
Elpaulo has joined #panfrost
<alyssa> Ugh this series is going to conflict pretty bad with the fp16 series. Meh.
<alyssa> This is the bigger/more important one, it wins, I'll try to add on fp16 to it later but honestly let's get this to the finish line first.
maccraft123 has quit [Ping timeout: 240 seconds]
maccraft123 has joined #panfrost
maccraft123 has quit [Ping timeout: 246 seconds]
maccraft123 has joined #panfrost
davidlt has quit [Ping timeout: 246 seconds]
maccraft123 has quit [Quit: WeeChat 2.6]
davidlt has joined #panfrost
davidlt has quit [Ping timeout: 240 seconds]
BenG83 has quit [Ping timeout: 265 seconds]
pH5 has quit [Ping timeout: 265 seconds]
karolherbst has quit [Remote host closed the connection]
karolherbst has joined #panfrost