--- Log opened Thu Nov 17 00:00:19 2022 00:24 -!- gleb0712250 [~gleb@178.150.137.228] has quit [Ping timeout: 240 seconds] 00:35 -!- gleb0712250 [~gleb@178.150.137.228] has joined #secp256k1 01:44 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has quit [Quit: My iMac has gone to sleep. ZZZzzz…] 01:44 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has joined #secp256k1 01:50 -!- laanwj [~laanwj@user/laanwj] has quit [Ping timeout: 255 seconds] 03:53 -!- roconnor [~quassel@coq/roconnor] has quit [Ping timeout: 260 seconds] 03:56 -!- roconnor [~quassel@coq/roconnor] has joined #secp256k1 04:22 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has quit [Quit: My iMac has gone to sleep. ZZZzzz…] 04:32 -!- midnight [~midnight@user/midnight] has quit [Ping timeout: 240 seconds] 04:36 -!- midnight [~midnight@user/midnight] has joined #secp256k1 04:42 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has joined #secp256k1 05:10 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has quit [Quit: My iMac has gone to sleep. ZZZzzz…] 05:13 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has joined #secp256k1 06:37 < roconnor> sipa: ^^ 07:46 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has quit [Quit: My iMac has gone to sleep. ZZZzzz…] 07:51 -!- halosghost [~halosghos@user/halosghost] has joined #secp256k1 07:52 < roconnor> Although I don't think I have much influance, I've personally decided that (mod n) means (Z/nZ) and in particular (mod 0) means (Z/0Z) = Z, and thus x mod 0 = x for all x:Z. 07:52 < sipa> roconnor: Hmm, are you suggesting something like `return (int64_t)((uint64_t)a * (uint64_t)b)` ? 07:52 < sipa> Just `a * b` will cause a signed integer overflow. 07:52 < sipa> Which cppreference says is UB. I'm surprised ubsan doesn't complain. 07:52 < sipa> Oh, but ubsan isn't enabled on any of the platforms where that code path is tested. 07:52 < sipa> Added a commit to address that in #1156 07:52 < sipa> Ok, by forcing that codepath to be used (using the inline asm replacement for _mulh and _umulh) and enabling ubsan, it triggers. 07:52 < sipa> And by changing to `(uint64_t)a * (uint64_t)b` it doesn't. 07:53 < sipa> That makes sense. It means that that "the integers mod n" have characteristic n. 07:58 < roconnor> it also makes the equation x = (x `div` 0)*0 + (x `mod` 0) work out, which is promising. ... for some definition of work out. 07:58 < sipa> Even for n=0. 07:59 < roconnor> I was about to say my IRC client is acting weird, however https://gnusha.org/secp256k1/2022-11-17.log suggests that sipa, it is your IRC client that is buffering things oddly. 07:59 < sipa> Also gcd(a,0) = a. 08:01 < roconnor> - 08:01 < sipa> Not my client, but the matrix-IRC bridge seems to have some latency... 08:01 < sipa> Also gcd(a,b) = gcd(a,b mod a) = gcd(a mod b, b) 08:01 < sipa> Keeps working when a=0 or b=0. 08:05 < roconnor> I brought this up because of your mod infinity comment in mulmod256. I don't actually think you should change your comment. I just wish we could. 08:10 < andytoshi> this is a really cool observation roconnor 08:16 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has joined #secp256k1 09:52 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has quit [Quit: My iMac has gone to sleep. ZZZzzz…] 09:56 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has joined #secp256k1 10:06 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has quit [Quit: My iMac has gone to sleep. ZZZzzz…] 10:14 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has joined #secp256k1 10:18 < roconnor> Do we need new configurations to run UBSAN through these codepaths. That sounds irritating to do. We'd have to do something like link against an implementation of __umulh and __mulh? 10:27 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has quit [Quit: My iMac has gone to sleep. ZZZzzz…] 10:49 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has joined #secp256k1 11:01 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has quit [Quit: My iMac has gone to sleep. ZZZzzz…] 11:20 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has joined #secp256k1 11:32 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has quit [Quit: My iMac has gone to sleep. ZZZzzz…] 11:47 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has joined #secp256k1 12:07 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has quit [Quit: My iMac has gone to sleep. ZZZzzz…] 12:53 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has joined #secp256k1 14:34 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has quit [Quit: My iMac has gone to sleep. ZZZzzz…] 14:37 -!- halosghost [~halosghos@user/halosghost] has quit [Quit: WeeChat 3.7.1] 15:16 -!- luke-jr [~luke-jr@user/luke-jr] has quit [Ping timeout: 268 seconds] 15:17 -!- lukedashjr [~luke-jr@user/luke-jr] has joined #secp256k1 15:18 -!- lukedashjr is now known as luke-jr 15:27 -!- luke-jr [~luke-jr@user/luke-jr] has quit [Ping timeout: 256 seconds] 15:50 -!- luke-jr [~luke-jr@user/luke-jr] has joined #secp256k1 17:59 -!- jon_atack [~jonatack@user/jonatack] has joined #secp256k1 18:02 -!- jonatack [~jonatack@user/jonatack] has quit [Ping timeout: 260 seconds] 20:09 -!- jonatack1 [~jonatack@user/jonatack] has joined #secp256k1 20:11 -!- jon_atack [~jonatack@user/jonatack] has quit [Ping timeout: 260 seconds] 23:02 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has joined #secp256k1 23:16 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has quit [Quit: My iMac has gone to sleep. ZZZzzz…] 23:43 -!- tromp [~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl] has joined #secp256k1 --- Log closed Fri Nov 18 00:00:20 2022