--- Day changed Sat Aug 04 2018 00:04 -!- n00bington [~tor@193.180.255.201] has quit [Remote host closed the connection] 00:25 -!- govg [~govg@c-67-167-240-78.hsd1.il.comcast.net] has joined #secp256k1 00:25 -!- govg is now known as Guest5790 00:26 -!- Guest5790 [~govg@c-67-167-240-78.hsd1.il.comcast.net] has quit [Killed (Sigyn (Spam is off topic on freenode.))] 00:46 -!- Madkiss15 [~Madkiss@c-73-32-163-129.hsd1.tx.comcast.net] has joined #secp256k1 00:46 -!- Madkiss15 [~Madkiss@c-73-32-163-129.hsd1.tx.comcast.net] has quit [Remote host closed the connection] 03:25 -!- Arokh9 [~Arokh@p3EE3A330.dip0.t-ipconnect.de] has joined #secp256k1 03:26 -!- Arokh9 [~Arokh@p3EE3A330.dip0.t-ipconnect.de] has quit [K-Lined] 03:44 -!- dwC-- [~dwC--@pool-96-230-231-191.bstnma.fios.verizon.net] has joined #secp256k1 03:44 -!- dwC-- [~dwC--@pool-96-230-231-191.bstnma.fios.verizon.net] has quit [K-Lined] 04:36 -!- Thorne [~Thorne@156.205.137.86] has joined #secp256k1 04:38 -!- Thorne [~Thorne@156.205.137.86] has quit [Remote host closed the connection] 04:40 -!- kameloso0 [~kameloso@p110.net118151199.tokai.or.jp] has joined #secp256k1 04:41 -!- kameloso0 [~kameloso@p110.net118151199.tokai.or.jp] has quit [Killed (Sigyn (Spam is off topic on freenode.))] 04:48 -!- lstanley1 [~lstanley@113.172.162.71] has joined #secp256k1 04:54 -!- lstanley1 [~lstanley@113.172.162.71] has quit [Ping timeout: 268 seconds] 04:56 -!- edong2317 [~edong23@89.148.165.104] has joined #secp256k1 04:59 -!- edong2317 [~edong23@89.148.165.104] has quit [Read error: Connection reset by peer] 05:05 -!- Vlad9 [~Vlad@113.168.178.56] has joined #secp256k1 05:07 -!- Vlad9 [~Vlad@113.168.178.56] has quit [Read error: Connection reset by peer] 05:10 -!- mon1 [~mon@86.57.208.178] has joined #secp256k1 05:11 -!- mon1 [~mon@86.57.208.178] has quit [Killed (Sigyn (Spam is off topic on freenode.))] 05:26 -!- Immune [~Immune@14.45.189.225] has joined #secp256k1 05:28 -!- Immune [~Immune@14.45.189.225] has quit [Remote host closed the connection] 05:42 -!- iownall5559 [~iownall55@141.136.64.61] has joined #secp256k1 05:47 -!- iownall5559 [~iownall55@141.136.64.61] has quit [Ping timeout: 260 seconds] 07:45 < roconnor> https://github.com/bitcoin-core/secp256k1/blob/master/src/field_10x26_impl.h#L391 07:46 < roconnor> Can a C expert explain how integer promotion works in this mixture of signed integer, unsigned integers and literals? 08:01 < roconnor> Okay, adding in precidence and assocaitivity we get ((0x3FFFC2FUL * 2) * (m + 1)) - (a->n[0]); 08:02 < roconnor> The 2 is promoted to a unsigned long so (0x3FFFC2FUL * 2) is unsigned long 08:02 < roconnor> 1 is promoted to a (signed) int so that (m + 1) is a signed int. 08:03 < roconnor> The signed int is promoted to an unsigned long when multiplied by an unsigned long making ((0x3FFFC2FUL * 2) * (m + 1)) an unsigned long 08:04 < roconnor> (a->n[0]) is a uint32_t which is unsigned. 08:05 < roconnor> It is promoted (or is maybe already) an unsigned long when subtracted. 08:05 < roconnor> making ((0x3FFFC2FUL * 2) * (m + 1)) - (a->n[0]) an unsigned long 08:05 -!- Razesdark [~Razesdark@180.65.167.235] has joined #secp256k1 08:05 < roconnor> and that whole thing is assigned to a uint32_t variable, which may truncate the result if it is unsigned long is larger than an uint32_t. 08:06 < roconnor> Think that is correct? 08:07 -!- Razesdark [~Razesdark@180.65.167.235] has quit [Remote host closed the connection] 08:09 < andytoshi> that is what i almost typed, then didn't hit enter because i was unsure 08:11 < andytoshi> you can ask in #c (or is it ##c ?) .. they are pedantic and smug but they love stuff like this 08:12 < roconnor> ugh. I don't know how I feel about venturing into #c. 08:12 < andytoshi> lol. yep 08:13 < roconnor> the conversion of negative valued signed integers to unsigned integers is well-defined on all inputs, correct? 08:15 < andytoshi> i _think_ the answer is yes, though i'm hesitant because C definitely does not require 2s complement representation of signed numbers (which is why signed overflow is undefined). in this case we could add an assert that `m` is always nonnegative 08:15 < roconnor> I bring this up because I was reading https://wiki.sei.cmu.edu/confluence/display/c/INT02-C.+Understand+integer+conversion+rules 08:16 < roconnor> which, BTW, has not made me understand integer conversion rules. 08:16 < roconnor> anyhow, it says "By the conversion rules, si is converted to an unsigned int. Because −1 cannot be represented as an unsigned int value, the −1 is converted to UINT_MAX in accordance with the C Standard, subclause 6.3.1.3, paragraph 2" 08:16 < roconnor> then gives me a link to buy the C standard for like $1000 or something. 08:17 < roconnor> (j/k) 08:17 < andytoshi> there are drafts of the standard that you can download for free 08:17 < andytoshi> i certainly hope these rules did not change between drafts :) 08:18 < andytoshi> http://www.open-std.org/JTC1/sc22/wg14/www/docs/n1256.pdf 08:19 < andytoshi> yeah, a signed->unsigned conversion (of same width, in this case there is first a sign-extension) takes the value and keeps adding/subtracting UINT_MAX+1 til it gets something in range 08:21 < roconnor> okay so it sounds like the only value of m that leads to undefined or unspecified behaviour is when m is equal to MAX_INT. 08:22 < roconnor> (of course, this function is only ever called when m is a small literal value). 08:24 < andytoshi> i could've sworn UINT_MAX was required to be strictly greated than INT_MAX, so even INT_MAX is fine 08:25 < andytoshi> but i can't find that now (it maybe be implicit in the integer sizing rules) 08:25 -!- NyanCat7 [~NyanCat@ip68-8-35-186.sd.sd.cox.net] has joined #secp256k1 08:25 < roconnor> but (m + 1) will overflow first, before being promoted ... I think. 08:26 < roconnor> I mean with C, who the fuck knows. 08:26 < roconnor> \me eyes ##c again 08:26 < andytoshi> oh right! 08:26 -!- NyanCat7 [~NyanCat@ip68-8-35-186.sd.sd.cox.net] has quit [Remote host closed the connection] 08:26 < andytoshi> yeah that's undefined. the compiler can assume that `m` is never equal to INT_MAX 08:27 < andytoshi> and optimize accordingly :P 08:27 < roconnor> well it can now! 08:27 < roconnor> right 08:27 < roconnor> I miss read you at first. 08:34 -!- deetwelve24 [~deetwelve@2804:18:6005:f490:bfcc:3520:895c:da9c] has joined #secp256k1 08:39 -!- deetwelve24 [~deetwelve@2804:18:6005:f490:bfcc:3520:895c:da9c] has quit [Remote host closed the connection] 08:44 -!- iownall5555 [~iownall55@125.132.19.156] has joined #secp256k1 08:45 -!- iownall5555 [~iownall55@125.132.19.156] has quit [Killed (Sigyn (Spam is off topic on freenode.))] 09:13 <@gmaxwell> 20:59:53 < roconnor> but to compute -R you'd construct the y coordinate this *is* the quadratic residue. 09:13 <@gmaxwell> roconnor: the idea behind the choice of QR as the tie breaker is that in the single signature case we never construct R.y. 09:15 <@gmaxwell> Er construct R in projective coordinates and compare that it matches, while staying in projective coordinates by projecting the provided R.x and checking that the y/x^2 has the right quadratic residue. 09:17 -!- Eduard_Munteanu1 [~Eduard_Mu@vps7774.publiccloud.com.br] has joined #secp256k1 09:17 <@gmaxwell> "can be directly constructed from r by finding a y coordinate that is *not* a quadratic residue, which is precisely the same amount of work that construction R from r was" < it's not precisely the same amount of work when decompressing R in the batch verifier. The sqrt naturally produces the answer that is a QR, to get the answer that isn't one, we'd have to negate. 09:22 -!- snowolf21 [~snowolf@196.219.145.4] has joined #secp256k1 09:23 -!- Eduard_Munteanu1 [~Eduard_Mu@vps7774.publiccloud.com.br] has quit [Ping timeout: 264 seconds] 09:23 -!- snowolf21 [~snowolf@196.219.145.4] has quit [Killed (Sigyn (Spam is off topic on freenode.))] 09:33 -!- aOssed22 [~aOssed@14.246.158.7] has joined #secp256k1 09:39 -!- Guest79333 [~Guest7933@78.30.214.102] has joined #secp256k1 09:39 -!- aOssed22 [~aOssed@14.246.158.7] has quit [Remote host closed the connection] 09:41 -!- Guest79333 [~Guest7933@78.30.214.102] has quit [Remote host closed the connection] 09:44 -!- tallguy8 [~tallguy@176.99.192.79] has joined #secp256k1 09:44 -!- tallguy8 [~tallguy@176.99.192.79] has quit [Remote host closed the connection] 09:53 < roconnor> [12:15] Er construct R in projective coordinates and compare that it matches, while staying in projective coordinates by projecting the provided R.x and checking that the y/x^2 has the right quadratic residue. 09:53 < roconnor> I don't follow this. 09:59 < roconnor> maybe I don't know what projective coordinates are? 10:05 -!- Guest12306 [~czart_@119.42.86.108] has joined #secp256k1 10:10 -!- Guest12306 [~czart_@119.42.86.108] has quit [Ping timeout: 244 seconds] 10:16 -!- sipa [~pw@unaffiliated/sipa1024] has joined #secp256k1 10:21 -!- Ryuzaki [~Ryuzaki@114.143.33.199] has joined #secp256k1 10:26 -!- sipa_ [~pw@2001:19f0:ac01:2fb:5400:ff:fe5b:c3ff] has joined #secp256k1 10:27 -!- Ryuzaki [~Ryuzaki@114.143.33.199] has quit [Ping timeout: 260 seconds] 10:28 -!- sipa [~pw@unaffiliated/sipa1024] has quit [Ping timeout: 256 seconds] 10:28 -!- Lightsword [~Lightswor@2604:a880:1:20::1d3:9001] has quit [Ping timeout: 256 seconds] 10:29 -!- Lightsword [~Lightswor@2604:a880:1:20::1d3:9001] has joined #secp256k1 10:45 -!- cats15 [~cats@i114-189-79-147.s41.a029.ap.plala.or.jp] has joined #secp256k1 10:46 -!- cats15 [~cats@i114-189-79-147.s41.a029.ap.plala.or.jp] has quit [Read error: Connection reset by peer] 10:57 -!- sipa_ [~pw@2001:19f0:ac01:2fb:5400:ff:fe5b:c3ff] has quit [Changing host] 10:57 -!- sipa_ [~pw@unaffiliated/sipa1024] has joined #secp256k1 10:57 -!- sipa_ is now known as sipa 11:10 -!- deusexbeer [~deusexbee@093-092-177-054-dynamic-pool-adsl.wbt.ru] has quit [Ping timeout: 260 seconds] 11:11 -!- deusexbeer [~deusexbee@080-250-076-176-dynamic-pool-adsl.wbt.ru] has joined #secp256k1 11:27 -!- Olipro22 [~Olipro@116.96.74.157] has joined #secp256k1 11:29 -!- Olipro22 [~Olipro@116.96.74.157] has quit [Remote host closed the connection] 11:37 -!- GTAXL23 [~GTAXL@106.226.11.227] has joined #secp256k1 11:41 -!- Zuu_ [~Zuu_@222.109.254.183] has joined #secp256k1 11:42 -!- Zuu_ [~Zuu_@222.109.254.183] has quit [Remote host closed the connection] 11:43 -!- GTAXL23 [~GTAXL@106.226.11.227] has quit [Ping timeout: 260 seconds] 12:06 -!- epic18 [~epic@host-static-188-237-103-220.moldtelecom.md] has joined #secp256k1 12:12 -!- epic18 [~epic@host-static-188-237-103-220.moldtelecom.md] has quit [Ping timeout: 240 seconds] 12:39 -!- deusexbeer [~deusexbee@080-250-076-176-dynamic-pool-adsl.wbt.ru] has quit [Quit: Konversation terminated!] 12:52 -!- lutoma14 [~lutoma@168-205-38-247.wantel.net.br] has joined #secp256k1 12:58 -!- lutoma14 [~lutoma@168-205-38-247.wantel.net.br] has quit [Ping timeout: 240 seconds] 13:02 -!- d1b12 [~d1b@05408b48.skybroadband.com] has joined #secp256k1 13:04 -!- d1b12 [~d1b@05408b48.skybroadband.com] has quit [Remote host closed the connection] 13:25 -!- vdamewood [~vdamewood@121.129.7.172] has joined #secp256k1 13:25 -!- vdamewood [~vdamewood@121.129.7.172] has quit [Remote host closed the connection] 13:40 -!- lynxis13 [~lynxis@113.169.16.251] has joined #secp256k1 13:41 -!- lynxis13 [~lynxis@113.169.16.251] has quit [Killed (Unit193 (Spam is not permitted on freenode.))] 14:06 -!- jrg28 [~jrg@14.186.163.172] has joined #secp256k1 14:10 -!- jrg28 [~jrg@14.186.163.172] has quit [Ping timeout: 240 seconds] 14:27 -!- We4 [~We@186-45-255-209.dynamic.tstt.net.tt] has joined #secp256k1 14:28 -!- We4 [~We@186-45-255-209.dynamic.tstt.net.tt] has quit [Remote host closed the connection] 14:40 -!- JustTheDoctor23 [~JustTheDo@184.82.53.240] has joined #secp256k1 14:45 -!- JustTheDoctor23 [~JustTheDo@184.82.53.240] has quit [Ping timeout: 240 seconds] 15:09 -!- agris_ [~agris@gateway/tor-sasl/agris] has joined #secp256k1 15:09 -!- agris [~agris@gateway/tor-sasl/agris] has quit [Remote host closed the connection] 16:02 -!- Natechip [~Natechip@117.5.132.184] has joined #secp256k1 16:06 -!- Natechip [~Natechip@117.5.132.184] has quit [Remote host closed the connection] 16:07 -!- Guest54806 [~GrapeNinj@117.1.210.244] has joined #secp256k1 16:12 -!- Guest54806 [~GrapeNinj@117.1.210.244] has quit [Ping timeout: 268 seconds] 16:22 -!- Pugabyte20 [~Pugabyte@116.107.159.121] has joined #secp256k1 16:28 -!- Pugabyte20 [~Pugabyte@116.107.159.121] has quit [Ping timeout: 248 seconds] 16:29 -!- em [~em@62.28.64.78] has joined #secp256k1 16:30 -!- em [~em@62.28.64.78] has quit [Remote host closed the connection] 16:46 -!- badet0s19 [~badet0s@14.169.83.93] has joined #secp256k1 16:49 -!- badet0s19 [~badet0s@14.169.83.93] has quit [Remote host closed the connection] 17:17 -!- agris_ [~agris@gateway/tor-sasl/agris] has quit [Remote host closed the connection] 17:17 -!- agris_ [~agris@gateway/tor-sasl/agris] has joined #secp256k1 17:26 -!- johnlage8 [~johnlage@123.23.166.63] has joined #secp256k1 17:30 -!- johnlage8 [~johnlage@123.23.166.63] has quit [Ping timeout: 240 seconds] 17:32 -!- Torgeir [~Torgeir@118.174.19.62] has joined #secp256k1 17:37 -!- Torgeir [~Torgeir@118.174.19.62] has quit [Ping timeout: 240 seconds] 17:46 -!- MillerBoss25 [~MillerBos@197.226.17.98] has joined #secp256k1 17:47 -!- MillerBoss25 [~MillerBos@197.226.17.98] has quit [Killed (Sigyn (Spam is off topic on freenode.))] 18:20 -!- CodeShark_ [sid126576@gateway/web/irccloud.com/x-ypywunmdwjjwuxld] has joined #secp256k1 18:20 -!- CodeShark_ [sid126576@gateway/web/irccloud.com/x-ypywunmdwjjwuxld] has quit [Client Quit] 18:21 -!- CodeShark_ [sid126576@gateway/web/irccloud.com/x-fndbcsezbqxvnkah] has joined #secp256k1 18:22 -!- CodeShark_ [sid126576@gateway/web/irccloud.com/x-fndbcsezbqxvnkah] has quit [Client Quit] 18:23 -!- CodeShark_ [sid126576@gateway/web/irccloud.com/x-plecbezedjqmbfvi] has joined #secp256k1 18:24 -!- CodeShark_ [sid126576@gateway/web/irccloud.com/x-plecbezedjqmbfvi] has quit [Client Quit] 18:26 -!- CodeShark [sid126576@gateway/web/irccloud.com/x-ybxkkaecapudurmr] has joined #secp256k1 18:45 -!- Ishaq21 [~Ishaq@95.107.199.160] has joined #secp256k1 18:49 -!- Ishaq21 [~Ishaq@95.107.199.160] has quit [Remote host closed the connection] 18:53 -!- liste11 [~liste@178.134.32.242] has joined #secp256k1 19:00 -!- liste11 [~liste@178.134.32.242] has quit [Ping timeout: 244 seconds] 19:20 -!- stoner197 [~stoner19@42.82.185.245] has joined #secp256k1 19:22 -!- stoner197 [~stoner19@42.82.185.245] has quit [Remote host closed the connection] 19:23 -!- n-st1 [~n-st@host130.181-13-156.telecom.net.ar] has joined #secp256k1 19:28 -!- deusexbeer [~deusexbee@080-250-076-176-dynamic-pool-adsl.wbt.ru] has joined #secp256k1 19:29 -!- n-st1 [~n-st@host130.181-13-156.telecom.net.ar] has quit [Ping timeout: 240 seconds] 20:08 -!- Grimnir25 [~Grimnir@186.179.100.99] has joined #secp256k1 20:14 -!- Grimnir25 [~Grimnir@186.179.100.99] has quit [Ping timeout: 260 seconds] 21:03 -!- mub17 [~mub@27.73.101.163] has joined #secp256k1 21:08 -!- mub17 [~mub@27.73.101.163] has quit [Remote host closed the connection] 22:03 -!- themill11 [~themill@181.128.94.122] has joined #secp256k1 22:08 -!- themill11 [~themill@181.128.94.122] has quit [Ping timeout: 244 seconds] 22:35 -!- Whooa21 [~Whooa21@143.95.0.1.megaegg.ne.jp] has joined #secp256k1 22:37 -!- Whooa21 [~Whooa21@143.95.0.1.megaegg.ne.jp] has quit [Remote host closed the connection] 23:28 -!- heinrich599124 [~heinrich5@140.224.123.195] has joined #secp256k1 23:28 -!- heinrich599124 [~heinrich5@140.224.123.195] has quit [Killed (Sigyn (Spam is off topic on freenode.))] 23:31 -!- krushia [~krushia@113.173.163.130] has joined #secp256k1 23:37 -!- krushia [~krushia@113.173.163.130] has quit [Ping timeout: 256 seconds]