marcan changed the topic of #asahi-re to: Asahi Linux: porting Linux to Apple Silicon macs | Hardware / boot process / firmware interface reverse engineering | WARNING: this channel (only) may contain binary reverse engineering discussion | RE policy: https://alx.sh/re (MANDATORY READ) | GitHub: https://alx.sh/g | Wiki: https://alx.sh/w | Logs: https://alx.sh/l/asahi-re
danb91 has quit [Remote host closed the connection]
Tokamak has joined #asahi-re
danb91 has joined #asahi-re
danb91 has quit [Ping timeout: 265 seconds]
danb91 has joined #asahi-re
danb91 has quit [Ping timeout: 240 seconds]
Tokamak has quit [Read error: Connection reset by peer]
Tokamak has joined #asahi-re
<hthh_> i started looking at documenting the GPU ISA (note this is based on mtl-gpu-asmcheck): https://hthh.github.io/m1-gpu-re/
Tokamak has quit [Ping timeout: 240 seconds]
Tokamak has joined #asahi-re
jcs has quit [Ping timeout: 240 seconds]
jcs has joined #asahi-re
danb91 has joined #asahi-re
danb91 has quit [Ping timeout: 264 seconds]
danb91 has joined #asahi-re
danb91 has quit [Ping timeout: 260 seconds]
danb91 has joined #asahi-re
danb91 has quit [Ping timeout: 265 seconds]
DragoonAethis has quit [Quit: hej-hej!]
DragoonAethis has joined #asahi-re
<davidrysk[m]> hthh_: those special registers seem similar to the grid/thread/block stuff that cuda and other gpu compute frameworks use
<davidrysk[m]> I would not be surprised if they're used for that, e.g. threadgroup_position_in_grid.x always returns the appropriate value for the block in which you are currently executing in
danb91 has joined #asahi-re
taziden has quit [Ping timeout: 264 seconds]
danb91 has quit [Ping timeout: 256 seconds]
<hthh_> yeah, i think that's how it works - the SRx names are from mtl-gpu-asmcheck, and the other names are my attempt at mapping the attributes in the metal shading language back to them - not sure if it actually stands for "special register" though
Necrosporus_ has joined #asahi-re
Necrosporus is now known as Guest10337
Guest10337 has quit [Read error: Connection reset by peer]
danb91 has joined #asahi-re
taziden has joined #asahi-re
<davidrysk[m]> it's possible that the runtime populates them as needed
<davidrysk[m]> but yeah more likely that the hardware does
<davidrysk[m]> are there other instructions than those?
danb91 has quit [Remote host closed the connection]
danb91 has joined #asahi-re
danb91 has quit [Ping timeout: 246 seconds]
<hthh_> oh so many - unfortunately llvm considers each combination of opcode and output sizes to be a distinct instruction, so the reversing process is still very manual, either getting the compiler to generate opcodes from known code, or constructing it myself to run on the gpu and check its behavior
<hthh_> (the hope is the operands stay pretty consistent and i can just write hardware tests to automate verification of my assumptions)
<marcan> hthh_: make sure the documentation strictly documents the instructions, and not anything about what llvm does
<marcan> as long as you write clean docs that we can use to write a clean-room implementation, this is valuable work
<marcan> but if LLVMisms from Apple's implementation leak into the docs, that can taint them
danb91 has joined #asahi-re
<marcan> alyssa has been doing this completely black-box up to this point, without any internal APIs; we ban outright decompilation of the GPU stack because it's just not needed; using internal APIs to get more information about the ISA is more of a grey area, but if it goes through clean-room docs that should be fine. let's keep it that way.
danb91 has quit [Ping timeout: 264 seconds]
<hthh_> sure, yeah, clean-room docs is my goal - i currently document what the compiler outputs in a few places, which isn't "just the instructions" but is what alyssa is looking at too - but yeah, i intend to clean it up a bit in that respect. (i'm also considering register names to be "facts" - lots of grey areas)
<marcan> register names are OK
<marcan> things like uX / srX are not a problem
<marcan> for long-form register names, I would encourage you to make up your own interpretation about what they do and use that name
<marcan> this does mean that you should stay on that side of the clean room, so no contributing to Mesa please :)
<marcan> (code, I mean)
<marcan> I've asked Alyssa what she thinks about this approach
dumenci has joined #asahi-re
<hthh_> sounds good, yeah - i won't be contributing code, and that's exactly what i've been doing for long-form names (mnemonics are also completely made up)
dumenci has quit [Quit: Leaving]
Tokamak has quit [Ping timeout: 264 seconds]
browzing_ has joined #asahi-re
browzing has quit [Ping timeout: 246 seconds]
randohacker[m] has joined #asahi-re
_whitelogger has joined #asahi-re
maor26 has joined #asahi-re
DanB91 has joined #asahi-re
DanB91 has quit [Ping timeout: 256 seconds]
tiagom has joined #asahi-re
tiagom has quit [Quit: leaving]
tiagom has joined #asahi-re
ohnx has quit [Remote host closed the connection]
ohnx has joined #asahi-re
tiagom has quit [Quit: leaving]
tiagom has joined #asahi-re
Tokamak has joined #asahi-re
ohnx has quit [Read error: Connection reset by peer]
citruscitrus[m] has quit [*.net *.split]
liur[m] has quit [*.net *.split]
hypergenesis[m] has quit [*.net *.split]
thecake21[m] has quit [*.net *.split]
clayfreeman has quit [*.net *.split]
clayfreeman has joined #asahi-re
hypergenesis[m] has joined #asahi-re
liur[m] has joined #asahi-re
citruscitrus[m] has joined #asahi-re
thecake21[m] has joined #asahi-re
bakk[m] has quit [Ping timeout: 244 seconds]
wolf511[m] has quit [Ping timeout: 244 seconds]
hwatwasthat[m] has quit [Ping timeout: 244 seconds]
brentr123[m] has quit [Ping timeout: 244 seconds]
ah-[m] has quit [Ping timeout: 244 seconds]
fl35[m] has quit [Ping timeout: 240 seconds]
TellowKrinkle[m] has quit [Ping timeout: 240 seconds]
bjornjulander[m] has quit [Ping timeout: 240 seconds]
skillfulman23[m] has quit [Ping timeout: 240 seconds]
asmon[m] has quit [Ping timeout: 240 seconds]
nhlism[m] has quit [Ping timeout: 240 seconds]
Jamie[m] has quit [Ping timeout: 240 seconds]
jamesmunns[m] has quit [Ping timeout: 240 seconds]
redbluescreen[m] has quit [Ping timeout: 240 seconds]
svenpeter has quit [Ping timeout: 240 seconds]
rootspring[m] has quit [Ping timeout: 243 seconds]
fried_dede[m] has quit [Ping timeout: 243 seconds]
reispflanze[m] has quit [Ping timeout: 243 seconds]
jinen[m] has quit [Ping timeout: 243 seconds]
rockinrobstar[m] has quit [Ping timeout: 243 seconds]
khronokernel[m] has quit [Ping timeout: 243 seconds]
shawnj2[m] has quit [Ping timeout: 243 seconds]
bastilian has quit [Ping timeout: 243 seconds]
DrGit[m] has quit [Ping timeout: 243 seconds]
hipboi[m] has quit [Ping timeout: 243 seconds]
ConeOfAttack[m] has quit [Ping timeout: 260 seconds]
smist08[m] has quit [Ping timeout: 260 seconds]
mellotron1[m] has quit [Ping timeout: 260 seconds]
tarik02[m] has quit [Ping timeout: 260 seconds]
emily has quit [Ping timeout: 243 seconds]
blazra has quit [Ping timeout: 260 seconds]
os[m] has quit [Ping timeout: 246 seconds]
jevinskie[m] has quit [Ping timeout: 246 seconds]
sumoon[m] has quit [Ping timeout: 246 seconds]
ts170[m] has quit [Ping timeout: 246 seconds]
mcnight[m] has quit [Ping timeout: 246 seconds]
flokk[m] has quit [Ping timeout: 246 seconds]
winocm has quit [Ping timeout: 246 seconds]
nutmanja[m] has quit [Ping timeout: 246 seconds]
josiahmendes[m] has quit [Ping timeout: 246 seconds]
jrmuizel[m] has quit [Ping timeout: 265 seconds]
ronyrus[m] has quit [Ping timeout: 265 seconds]
mofux[m] has quit [Ping timeout: 265 seconds]
nufflee[m] has quit [Ping timeout: 265 seconds]
Bastian[m] has quit [Ping timeout: 265 seconds]
davidrysk[m] has quit [Ping timeout: 260 seconds]
Jasper[m] has quit [Ping timeout: 260 seconds]
randohacker[m] has quit [Ping timeout: 268 seconds]
iparaskev[m] has quit [Ping timeout: 268 seconds]
delroth[m] has quit [Ping timeout: 268 seconds]
xerpi[m] has quit [Ping timeout: 268 seconds]
enverb[m] has quit [Ping timeout: 268 seconds]
bylaws has quit [Ping timeout: 268 seconds]
_alice has quit [Ping timeout: 268 seconds]
konradybcio has quit [Ping timeout: 265 seconds]
citruscitrus[m] has quit [Ping timeout: 258 seconds]
hypergenesis[m] has quit [Ping timeout: 258 seconds]
liur[m] has quit [Ping timeout: 258 seconds]
thecake21[m] has quit [Ping timeout: 258 seconds]
vimal has joined #asahi-re
stemnic has quit [Quit: The Lounge - https://thelounge.chat]
jrmuizel[m] has joined #asahi-re
ronyrus[m] has joined #asahi-re
Bastian[m] has joined #asahi-re
konradybcio has joined #asahi-re
mofux[m] has joined #asahi-re
nufflee[m] has joined #asahi-re
wolf511[m] has joined #asahi-re
hwatwasthat[m] has joined #asahi-re
brentr123[m] has joined #asahi-re
ah-[m] has joined #asahi-re
bakk[m] has joined #asahi-re
emily has joined #asahi-re
jamesmunns[m] has joined #asahi-re
nhlism[m] has joined #asahi-re
svenpeter has joined #asahi-re
skillfulman23[m] has joined #asahi-re
asmon[m] has joined #asahi-re
TellowKrinkle[m] has joined #asahi-re
bylaws has joined #asahi-re
bjornjulander[m] has joined #asahi-re
fl35[m] has joined #asahi-re
Jamie[m] has joined #asahi-re
redbluescreen[m] has joined #asahi-re
enverb[m] has joined #asahi-re
delroth[m] has joined #asahi-re
xerpi[m] has joined #asahi-re
iparaskev[m] has joined #asahi-re
_alice has joined #asahi-re
randohacker[m] has joined #asahi-re
bastilian has joined #asahi-re
Jasper[m] has joined #asahi-re
TellowKrinkle[m] has quit [Ping timeout: 246 seconds]
asmon[m] has quit [Ping timeout: 241 seconds]
jrmuizel[m] has quit [Ping timeout: 241 seconds]
nhlism[m] has quit [Ping timeout: 240 seconds]
svenpeter has quit [Ping timeout: 240 seconds]
emily has quit [Ping timeout: 240 seconds]
nufflee[m] has quit [Ping timeout: 240 seconds]
ronyrus[m] has quit [Ping timeout: 258 seconds]
konradybcio has quit [Ping timeout: 258 seconds]
Bastian[m] has quit [Ping timeout: 268 seconds]
randohacker[m] has quit [Ping timeout: 265 seconds]
jamesmunns[m] has quit [Ping timeout: 265 seconds]
mofux[m] has quit [Ping timeout: 265 seconds]
Jasper[m] has quit [Ping timeout: 260 seconds]
skillfulman23[m] has quit [Ping timeout: 260 seconds]
delroth[m] has quit [Ping timeout: 240 seconds]
wolf511[m] has quit [Ping timeout: 240 seconds]
_alice has quit [Ping timeout: 240 seconds]
fl35[m] has quit [Ping timeout: 240 seconds]
redbluescreen[m] has quit [Ping timeout: 240 seconds]
brentr123[m] has quit [Ping timeout: 240 seconds]
ah-[m] has quit [Ping timeout: 240 seconds]
enverb[m] has quit [Ping timeout: 258 seconds]
xerpi[m] has quit [Ping timeout: 258 seconds]
bylaws has quit [Ping timeout: 258 seconds]
bastilian has quit [Ping timeout: 265 seconds]
bjornjulander[m] has quit [Ping timeout: 265 seconds]
hwatwasthat[m] has quit [Ping timeout: 265 seconds]
Jamie[m] has quit [Ping timeout: 260 seconds]
iparaskev[m] has quit [Ping timeout: 260 seconds]
bakk[m] has quit [Ping timeout: 268 seconds]
davidrysk[m] has joined #asahi-re
ryanhrob[m] has joined #asahi-re
flokk[m] has joined #asahi-re
hwatwasthat[m] has joined #asahi-re
iparaskev[m] has joined #asahi-re
khronokernel[m] has joined #asahi-re
nutmanja[m] has joined #asahi-re
mofux[m] has joined #asahi-re
_alice has joined #asahi-re
ts170[m] has joined #asahi-re
bjornjulander[m] has joined #asahi-re
redbluescreen[m] has joined #asahi-re
blazra has joined #asahi-re
bylaws has joined #asahi-re
svenpeter has joined #asahi-re
xerpi[m] has joined #asahi-re
reispflanze[m] has joined #asahi-re
ronyrus[m] has joined #asahi-re
thecake21[m] has joined #asahi-re
TellowKrinkle[m] has joined #asahi-re
randohacker[m] has joined #asahi-re
liur[m] has joined #asahi-re
jevinskie[m] has joined #asahi-re
brentr123[m] has joined #asahi-re
enverb[m] has joined #asahi-re
ah-[m] has joined #asahi-re
DrGit[m] has joined #asahi-re
fried_dede[m] has joined #asahi-re
skillfulman23[m] has joined #asahi-re
Bastian[m]1 has joined #asahi-re
Jamie[m] has joined #asahi-re
rockinrobstar[m] has joined #asahi-re
sumoon[m] has joined #asahi-re
bastilian has joined #asahi-re
tarik02[m] has joined #asahi-re
smist08[m] has joined #asahi-re
hipboi[m] has joined #asahi-re
josiahmendes[m] has joined #asahi-re
nufflee[m] has joined #asahi-re
asmon[m] has joined #asahi-re
shawnj2[m] has joined #asahi-re
citruscitrus[m] has joined #asahi-re
Jasper[m] has joined #asahi-re
hypergenesis[m] has joined #asahi-re
mellotron1[m] has joined #asahi-re
jamesmunns[m] has joined #asahi-re
os[m] has joined #asahi-re
konradybcio has joined #asahi-re
rootspring[m] has joined #asahi-re
mcnight[m] has joined #asahi-re
delroth[m] has joined #asahi-re
wolf511[m] has joined #asahi-re
fl35[m] has joined #asahi-re
bakk[m] has joined #asahi-re
nhlism[m] has joined #asahi-re
ConeOfAttack[m] has joined #asahi-re
emily has joined #asahi-re
winocm has joined #asahi-re
jinen[m] has joined #asahi-re
jrmuizel[m] has joined #asahi-re
Tokamak has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
DanB91 has joined #asahi-re
Bastian[m]1 is now known as Bastian[m]
DanB91 has quit [Ping timeout: 272 seconds]
_whitelogger has joined #asahi-re
<marcan> hthh_: alyssa says your approach sounds good, just one thing (PM)
baryluk has joined #asahi-re
vimal has quit [Remote host closed the connection]
vimal has joined #asahi-re
Tokamak has joined #asahi-re
vimal has quit [Remote host closed the connection]
zopieux has quit [Ping timeout: 260 seconds]
zopieux has joined #asahi-re
maor26 has quit [Remote host closed the connection]
maor26 has joined #asahi-re
DanB91 has joined #asahi-re
DanB91 has quit [Ping timeout: 260 seconds]
alula__ has joined #asahi-re
vimal has joined #asahi-re
alula_ has quit [Ping timeout: 240 seconds]
vimal has quit [Remote host closed the connection]
vimal has joined #asahi-re
DanB91 has joined #asahi-re
DanB91 has quit [Ping timeout: 246 seconds]
vimal has quit [Remote host closed the connection]
vimal has joined #asahi-re
DanB91 has joined #asahi-re
Tokamak has quit [Ping timeout: 260 seconds]
DanB91 has quit [Remote host closed the connection]
DanB91 has joined #asahi-re
DanB91 has quit [Remote host closed the connection]
DanB91 has joined #asahi-re
DanB91 has quit [Ping timeout: 260 seconds]
DanB91 has joined #asahi-re
maor26 has quit [Ping timeout: 256 seconds]
Tokamak has joined #asahi-re
DanB91 has quit [Remote host closed the connection]
tiagom has quit [Quit: leaving]
chrisf has joined #asahi-re
chrisf has left #asahi-re ["Leaving"]
DanB91 has joined #asahi-re