vagrantc has quit [Quit: leaving]
brook has quit [Ping timeout: 255 seconds]
brook has joined #beagle
brook has quit [Ping timeout: 256 seconds]
set_ has quit [Remote host closed the connection]
set_ has joined #beagle
<set_> Can I be the first one to say, "AW?"
<set_> forget it. It is figured out now. Odd days.
<set_> It seems when I flip out in #beagle, my woes are lessoned. Please forgive me.
CrazyEddy has quit [Remote host closed the connection]
CrazyEddy has joined #beagle
ikarso has quit [Quit: Connection closed for inactivity]
ft has quit [Ping timeout: 256 seconds]
ft has joined #beagle
brook has joined #beagle
CrazyEddy has quit [Remote host closed the connection]
CrazyEddy has joined #beagle
Shadyman has joined #beagle
brook has quit [Remote host closed the connection]
fuser has joined #beagle
<fuser> vears
<fuser> -*
fuser has left #beagle [#beagle]
balrog has quit [Ping timeout: 256 seconds]
balrog has joined #beagle
ikarso has joined #beagle
mvaittin has quit [Read error: Connection reset by peer]
florian has joined #beagle
rob_w has joined #beagle
rob_w has quit [Remote host closed the connection]
rob_w has joined #beagle
mvaittin has joined #beagle
Shadyman has quit [Quit: Leaving.]
starblue has quit [Ping timeout: 256 seconds]
starblue has joined #beagle
marcheu has quit [Ping timeout: 276 seconds]
marcheu has joined #beagle
_whitelogger has joined #beagle
ikarso has quit [Quit: Connection closed for inactivity]
mvaittin has quit [Ping timeout: 268 seconds]
buzzmarshall has joined #beagle
_whitelogger has joined #beagle
vagrantc has joined #beagle
Stat_headcrabed has joined #beagle
otisolsen70 has joined #beagle
otisolsen70 has quit [Remote host closed the connection]
<zmatt> dinuxbg: subtract uses carry as a borrow-flag, I'm aware
<zmatt> dinuxbg: hmm I see the linked issue is also using .w0 as output, which complicates things
florian has quit [Quit: Ex-Chat]
<zmatt> e.g. the carry-out of "add r0.w0, r1, r2" is equal to (((r1 + r2) >> 16) & 1)
<zmatt> if I remember correctly
jfsimon1981_b has joined #beagle
vagrantc has quit [Quit: leaving]
jfsimon1981_b has quit [Remote host closed the connection]
jfsimon1981_b has joined #beagle
jfsimon1981_b has quit [Read error: Connection reset by peer]
jfsimon1981_b has joined #beagle
jfsimon1981_b has quit [Remote host closed the connection]
jfsimon1981_b has joined #beagle
waldo323_ has quit [Remote host closed the connection]
Stat_headcrabed has quit [Quit: Stat_headcrabed]
Stat_headcrabed has joined #beagle
russ has quit [Ping timeout: 255 seconds]
CygniX_ has left #beagle [Konversation terminated!]
CygniX has joined #beagle
vagrantc has joined #beagle
russ has joined #beagle
<zmatt> dinuxbg: lol, gcc on 32-bit ARM is producing some "amazing" output for __builtin_addc: https://godbolt.org/z/79K79bbjf
russ has quit [Ping timeout: 260 seconds]
<zmatt> dinuxbg: that E2E thread claims pru uses the same convention as ARM, but that's just not true, it's the opposite convention of arm
<zmatt> dinuxbg: also I definitely fucked up in https://pastebin.com/hcGqGv2L ...
<zmatt> right? .. I think I did? now I'm starting to doubt again
<zmatt> no wait they _do_ use the same convention as arm, i.e. carry is just carry (i.e. not-borrow)
<zmatt> so there's no "unexpected behaviour" when mixing add/sub
<zmatt> which means I did get https://pastebin.com/hcGqGv2L correct
<zmatt> dinuxbg: just in case I've tested the sub+suc and sub+adc combinations against real hardware using py-uio: https://pastebin.com/X7Ka37Q5
<zmatt> so I don't know why I thought pru had an inverted meaning for the carry flag... the way it works is actually perfectly reasonable
<zmatt> *for the carry-flag when used with sub/suc
<zmatt> or at least it's how I'm used to add/sub-with-carry to work
ikarso has joined #beagle
outrageous has quit [Read error: Connection reset by peer]
russ has joined #beagle
Stat_headcrabed has quit [Quit: Connection closed for inactivity]
<zmatt> dinuxbg: actually, it looks like your pru simulator misimplements sub/suc ?
<zmatt> (in a way that causes incorrect results when passing carry from add/adc to sub/suc or vice versa)
<zmatt> ahhh so THAT's how the idea got into my head
<zmatt> I did in fact at some point consult your pru.isa file, that's probably how I started thinking pru treated it as a borrow-flag
<zmatt> dinuxbg: of course there is an oddity here: the ARM-style use of carry as "not borrow" stems from fact that this makes sbc( a, b, carry_in ) equivalent to adc( a, ~b, carry_in ) so in hardware that just means conditionally inverting the second argument depending on whether it's add or subtract (and that same conditional invert is also used to turn "and" into "bic" on ARM)
<zmatt> but this gets a bit funky for PRU with its ability to use 8- and 16-bit register fields as operands
<zmatt> if all operands are 16-bit then there's no problem except "~b" is a 16-bit invert
<zmatt> but pru allows b to be 32-bit even if the sub/suc has a 16-bit destination, which you need to compute (a + (b ^ 0xffff) + carry_in) to get the correct result in bits 0..15 and correct carry_out in bit 16
<zmatt> in the end of course it's the same as what you're doing except you need to invert the carry_in and carry_out for sub and suc
<zmatt> (and doing so is definitely more readable then what I just wrote above ;)
vvn has quit [Quit: WeeChat 4.0.5]
vvn has joined #beagle
ikarso has quit [Quit: Connection closed for inactivity]
rob_w has quit [Read error: Connection reset by peer]