marcan changed the topic of #asahi-gpu to: Asahi Linux: porting Linux to Apple Silicon macs | GPU / 3D graphics stack black-box RE and development (NO binary reversing) | Keep things on topic | GitHub: https://alx.sh/g | Wiki: https://alx.sh/w | Logs: https://alx.sh/l/asahi-gpu
JusticeEX has quit [Ping timeout: 245 seconds]
DragoonAethis has quit [Quit: hej-hej!]
DragoonAethis has joined #asahi-gpu
JusticeEX has joined #asahi-gpu
PhilippvK has joined #asahi-gpu
phiologe has quit [Ping timeout: 260 seconds]
JusticeEX has quit [Ping timeout: 256 seconds]
phire has joined #asahi-gpu
zkrx has quit [Ping timeout: 260 seconds]
zkrx has joined #asahi-gpu
maor26 has joined #asahi-gpu
Raqbit has quit [Ping timeout: 256 seconds]
ryanhrob[m] has quit [Quit: Idle for 30+ days]
Raqbit has joined #asahi-gpu
JusticeEX has joined #asahi-gpu
tomtastic_ has joined #asahi-gpu
tomtastic has quit [Ping timeout: 245 seconds]
tomtastic_ is now known as tomtastic
Mary_ has quit [Quit: Bye!]
tomtastic has quit [Read error: Connection reset by peer]
tomtastic has joined #asahi-gpu
skg has quit [Quit: 〜バイバイ〜!]
JusticeEX has quit [Ping timeout: 260 seconds]
skg has joined #asahi-gpu
Jasper[m] has quit [*.net *.split]
chrisf has quit [*.net *.split]
feuerrot has quit [*.net *.split]
neobrain has quit [*.net *.split]
modwizcode has quit [*.net *.split]
vup has quit [*.net *.split]
dhewg has quit [*.net *.split]
Augur[m] has quit [*.net *.split]
Bastian[m] has quit [*.net *.split]
morelightning[m] has quit [*.net *.split]
jn__ has quit [*.net *.split]
rbenua has quit [*.net *.split]
cyrozap has quit [*.net *.split]
anuejn has quit [*.net *.split]
cyrozap has joined #asahi-gpu
dhewg has joined #asahi-gpu
vup has joined #asahi-gpu
anuejn has joined #asahi-gpu
modwizcode has joined #asahi-gpu
jn__ has joined #asahi-gpu
feuerrot has joined #asahi-gpu
zzoon has quit [*.net *.split]
rockinrobstar[m] has quit [*.net *.split]
AkihikoOdaki[m] has quit [*.net *.split]
svenpeter has quit [*.net *.split]
simjnd[m] has quit [*.net *.split]
yrlf has quit [*.net *.split]
varad has quit [*.net *.split]
linuxgemini has quit [*.net *.split]
richbridger has quit [*.net *.split]
prusnak has quit [*.net *.split]
Emantor has quit [*.net *.split]
prusnak has joined #asahi-gpu
varad has joined #asahi-gpu
linuxgemini has joined #asahi-gpu
yrlf has joined #asahi-gpu
richbridger has joined #asahi-gpu
chrisf has joined #asahi-gpu
RiniaOk_yama[m] has quit [Ping timeout: 240 seconds]
emily has quit [Ping timeout: 240 seconds]
izzyisles[m] has quit [Ping timeout: 258 seconds]
blazra has quit [Ping timeout: 258 seconds]
winocm has quit [Ping timeout: 258 seconds]
bngs[m] has quit [Ping timeout: 240 seconds]
mofux[m] has quit [Ping timeout: 240 seconds]
Guest57260 has quit [Ping timeout: 244 seconds]
josiahmendes[m] has quit [Ping timeout: 272 seconds]
davidrysk[m] has quit [Ping timeout: 240 seconds]
OctopusET[m] has quit [Ping timeout: 240 seconds]
JJJollyjim has quit [Ping timeout: 240 seconds]
hypergenesis[m] has quit [Ping timeout: 240 seconds]
<DarkShadow44>
Main goal will be having a shader assembler/disassembler in C, that could be plugged into LLVM for bytecode generation
<DarkShadow44>
Still in its early stages though...
<DarkShadow44>
Most of understanding is based on dougallj
<DarkShadow44>
Does this sound like a useful undertaking to you?
<daniels>
DarkShadow44: it depends on what your end goal is - ultimately the results of the GPU reverse engineering will result in a Mesa driver which uses Mesa's NIR compiler framework rather than LLVM
taowa has quit [Changing host]
taowa has joined #asahi-gpu
<daniels>
NIR (like SSA) is a mostly-architecture-independent SSA IR which is good for transformations and optimisations
<daniels>
each driver (and generation within the driver) though has its own custom backend IR, which is a much closer fit to assembly and disassembly
<daniels>
so the short answer is that LLVM is not useful in and of itself. the driver won't use LLVM to implement a full compiler at any point; and for code generation and analysis in development, the driver will ultimately have its own bespoke backend IR, so a (dis)assembler will ultimately be targeted closer to that
<DarkShadow44>
well, I'm trying to 1) have a disassembler that can turn bytecode into readable assembly (for debugging)
<DarkShadow44>
and 2) to make an assembler for usage with mesa/nir
<DarkShadow44>
or whatever we end up using in the end
<DarkShadow44>
main part of that will be an immediate representation in form of structs that represent the operations the GPU can do
<chrisf>
DarkShadow44: id encourage you to enhance things that exist rather than building yet another one, if you can
<DarkShadow44>
As another abstraction, to make bytecode generation via NIR easier and more flexible when the architecture changes, e.g. with the next chips
<daniels>
oh no, please don't think about future architecture generations
<daniels>
if the new architecture has trivial changes, you don't need enough adaptation to have built an abstraction layer
<daniels>
it it has substantial changes, your abstraction layer is just going to get in the way
<DarkShadow44>
hmm depends on how much it changes
<chrisf>
or at least "not another layer beyond what we will need as the backend ir"
<DarkShadow44>
So you'd turn NIR code directly into G13 bytecode?
Raqbit has joined #asahi-gpu
<daniels>
nope, via a backend IR - I would recommend reading the blog post above to get a reasonable idea of the lines between the three (NIR, backend IR, bytecode)
<chrisf>
your instructions-as-structs model isnt wildly off
<DarkShadow44>
yeah, that's my IR
<DarkShadow44>
that's why I don't understand why you dislike that approach
<chrisf>
you need something like this. just no *additional* layer
<DarkShadow44>
layer in what sense?
j`ey_ is now known as j`ey
<chrisf>
in the short term i guess it doesnt matter if you go in slightly odd directions as long as it turns "?" bits into things we understand
<DarkShadow44>
well, my goal would also be to get the code upstreamed eventually
<DarkShadow44>
AFAIK there's no assembler project (in C) yet
KajetanPuchalski is now known as mrkajetanp[m]
<DarkShadow44>
Just need to flesh out the architekture, then I consider asking for integration
mrkajetanp[m] is now known as mrkajetanp
mrkajetanp has quit [Quit: authenticating]
mrkajetanp has joined #asahi-gpu
zkrx has quit [Ping timeout: 248 seconds]
balrog has quit [Quit: Bye]
balrog has joined #asahi-gpu
<bloom>
DarkShadow44: looks like you're having fun :)
<DarkShadow44>
bloom: Now that I finally figured out how device_load/store work, definitely :)
zkrx has joined #asahi-gpu
TheJollyRoger has quit [Ping timeout: 240 seconds]
bpye has joined #asahi-gpu
maor26 has quit [Quit: Leaving]
TheJollyRoger has joined #asahi-gpu
TheJollyRoger has quit [Ping timeout: 240 seconds]