2024/05/26

2024-05-26 00:03:13 +0200paddymahoney(~paddymaho@pool-99-250-26-190.cpe.net.cable.rogers.com)
2024-05-26 00:09:21 +0200misterfish(~misterfis@84.53.85.146) (Remote host closed the connection)
2024-05-26 00:11:08 +0200peterbecich(~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 252 seconds)
2024-05-26 00:13:41 +0200kadir(~kadir@88.251.51.100)
2024-05-26 00:15:59 +0200peterbecich(~Thunderbi@syn-047-229-123-186.res.spectrum.com)
2024-05-26 00:22:00 +0200euleritian(~euleritia@ip4d16fc38.dynamic.kabel-deutschland.de) (Ping timeout: 260 seconds)
2024-05-26 00:22:40 +0200euleritian(~euleritia@dynamic-176-006-185-100.176.6.pool.telefonica.de)
2024-05-26 00:25:32 +0200tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-05-26 00:29:07 +0200phma_phma
2024-05-26 00:30:45 +0200peterbecich(~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 268 seconds)
2024-05-26 00:34:10 +0200causal(~eric@50.35.88.207)
2024-05-26 00:34:54 +0200peterbecich(~Thunderbi@syn-047-229-123-186.res.spectrum.com)
2024-05-26 00:42:53 +0200titibandit(~user@user/titibandit) (Ping timeout: 240 seconds)
2024-05-26 00:45:35 +0200peterbecich(~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 264 seconds)
2024-05-26 00:50:01 +0200peterbecich(~Thunderbi@syn-047-229-123-186.res.spectrum.com)
2024-05-26 01:06:20 +0200peterbecich(~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 260 seconds)
2024-05-26 01:12:24 +0200acidjnk(~acidjnk@p200300d6e714dc042020e32aab5643b9.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2024-05-26 01:12:59 +0200wootehfoot(~wootehfoo@user/wootehfoot) (Quit: Leaving)
2024-05-26 01:13:14 +0200ChaiTRex(~ChaiTRex@user/chaitrex) (Ping timeout: 260 seconds)
2024-05-26 01:15:35 +0200ChaiTRex(~ChaiTRex@user/chaitrex)
2024-05-26 01:17:47 +0200target_i(~target_i@user/target-i/x-6023099) (Quit: leaving)
2024-05-26 01:24:43 +0200kadir(~kadir@88.251.51.100) (Quit: WeeChat 4.2.2)
2024-05-26 01:26:22 +0200gmg(~user@user/gehmehgeh) (Quit: Leaving)
2024-05-26 01:33:13 +0200hiredman(~hiredman@frontier1.downey.family) (Quit: Lost terminal)
2024-05-26 01:55:47 +0200waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se) (Ping timeout: 264 seconds)
2024-05-26 02:16:48 +0200gentauro(~gentauro@user/gentauro) (Read error: Connection reset by peer)
2024-05-26 02:21:00 +0200Lord_of_Life(~Lord@user/lord-of-life/x-2819915) (Ping timeout: 260 seconds)
2024-05-26 02:22:16 +0200Lord_of_Life(~Lord@user/lord-of-life/x-2819915)
2024-05-26 02:22:30 +0200gentauro(~gentauro@user/gentauro)
2024-05-26 02:24:37 +0200troydm(~troydm@user/troydm)
2024-05-26 02:32:36 +0200califax(~califax@user/califx) (Remote host closed the connection)
2024-05-26 02:34:12 +0200califax(~califax@user/califx)
2024-05-26 02:36:36 +0200o-90(~o-90@gateway/tor-sasl/o-90)
2024-05-26 02:40:14 +0200califax(~califax@user/califx) (Remote host closed the connection)
2024-05-26 02:40:43 +0200califax(~califax@user/califx)
2024-05-26 02:42:28 +0200Square2(~Square@user/square) (Ping timeout: 260 seconds)
2024-05-26 02:44:45 +0200Tuplanolla(~Tuplanoll@91-159-69-59.elisa-laajakaista.fi) (Quit: Leaving.)
2024-05-26 02:56:09 +0200califax(~califax@user/califx) (Remote host closed the connection)
2024-05-26 02:56:52 +0200califax(~califax@user/califx)
2024-05-26 03:01:17 +0200_d0t(~{-d0t-}@user/-d0t-/x-7915216) (Ping timeout: 240 seconds)
2024-05-26 03:03:15 +0200_d0t(~{-d0t-}@user/-d0t-/x-7915216)
2024-05-26 03:30:39 +0200madariaga(~madariaga@user/madariaga)
2024-05-26 03:31:09 +0200 <madariaga> hi, can tuples be added like vectors? as in (0, 1) + (1, 0) = (1, 1)
2024-05-26 03:31:29 +0200 <geekosaur> no
2024-05-26 03:31:29 +0200 <glguy> not without you adding an extra Num instance that isn't in the base package
2024-05-26 03:31:42 +0200 <madariaga> ok thanks
2024-05-26 03:31:54 +0200 <geekosaur> I'm not even sure how you would define it
2024-05-26 03:32:49 +0200 <glguy> instance (Num a, Num b) => Num (a, b) where (x,y) + (z,w) = (x+z,y+w); ... ; fromIntegral x = (fromIntegral x, fromIntegral x)
2024-05-26 03:32:51 +0200 <glguy> stuff like that I assume
2024-05-26 03:33:13 +0200 <c_wraith> If you want something that works like vectors, I'd really recommend using the linear package. V2 just does what you want
2024-05-26 03:33:18 +0200 <geekosaur> it's the ... that makes me wonder. what's abs? signum?
2024-05-26 03:33:44 +0200 <glguy> geekosaur: abs (x,y) = (abs x, abs y) ; same for signum
2024-05-26 03:42:51 +0200o-90(~o-90@gateway/tor-sasl/o-90) (Remote host closed the connection)
2024-05-26 03:44:22 +0200 <EvanR> V2 has a lot more support than you want to write yourself for subset of (,)
2024-05-26 03:44:44 +0200fizbin__(~fizbin@user/fizbin)
2024-05-26 03:56:23 +0200otto_s(~user@p5de2f67f.dip0.t-ipconnect.de) (Ping timeout: 264 seconds)
2024-05-26 03:57:38 +0200otto_s(~user@p4ff27cd0.dip0.t-ipconnect.de)
2024-05-26 04:00:01 +0200fliife(~fliife@user/fliife) (Quit: ZNC 1.8.2+deb2build5 - https://znc.in)
2024-05-26 04:00:51 +0200fliife(~fliife@user/fliife)
2024-05-26 04:05:02 +0200op_4(~tslil@user/op-4/x-9116473) (Remote host closed the connection)
2024-05-26 04:05:31 +0200op_4(~tslil@user/op-4/x-9116473)
2024-05-26 04:12:21 +0200ddellacosta(~ddellacos@ool-44c73d29.dyn.optonline.net)
2024-05-26 04:22:46 +0200Rodney_(~Rodney@176.254.244.83) (Read error: Connection reset by peer)
2024-05-26 04:30:46 +0200destituion(~destituio@2a02:2121:607:127a:8ad9:5c0a:45fb:3e09) (Ping timeout: 255 seconds)
2024-05-26 04:33:31 +0200tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-05-26 04:34:11 +0200tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Client Quit)
2024-05-26 04:34:25 +0200philopsos1(~caecilius@user/philopsos)
2024-05-26 04:59:00 +0200td_(~td@i53870937.versanet.de) (Ping timeout: 268 seconds)
2024-05-26 04:59:30 +0200fizbin__(~fizbin@user/fizbin) (Remote host closed the connection)
2024-05-26 05:00:29 +0200td_(~td@i5387093D.versanet.de)
2024-05-26 05:02:16 +0200machinedgod(~machinedg@d173-183-246-216.abhsia.telus.net) (Ping timeout: 255 seconds)
2024-05-26 05:10:16 +0200Sgeo(~Sgeo@user/sgeo)
2024-05-26 06:30:19 +0200xdminsy(~xdminsy@117.147.70.240) (Remote host closed the connection)
2024-05-26 06:30:47 +0200xdminsy(~xdminsy@117.147.70.240)
2024-05-26 06:53:45 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 07:06:55 +0200takuan(~takuan@178-116-218-225.access.telenet.be)
2024-05-26 07:51:05 +0200tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-05-26 07:54:18 +0200euleritian(~euleritia@dynamic-176-006-185-100.176.6.pool.telefonica.de) (Read error: Connection reset by peer)
2024-05-26 07:54:36 +0200euleritian(~euleritia@ip4d16fc38.dynamic.kabel-deutschland.de)
2024-05-26 08:05:18 +0200tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-05-26 08:05:32 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Remote host closed the connection)
2024-05-26 08:14:58 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 08:19:32 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 252 seconds)
2024-05-26 08:22:11 +0200euphores(~SASL_euph@user/euphores) (Quit: Leaving.)
2024-05-26 08:33:29 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 08:38:04 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 260 seconds)
2024-05-26 08:54:24 +0200notzmv(~daniel@user/notzmv) (Ping timeout: 260 seconds)
2024-05-26 08:57:29 +0200philopsos1(~caecilius@user/philopsos) (Ping timeout: 252 seconds)
2024-05-26 09:00:02 +0200tt1231097(~tt1231@2603:6010:8700:4a81:219f:50d3:618a:a6ee) (Quit: The Lounge - https://thelounge.chat)
2024-05-26 09:00:24 +0200tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-05-26 09:00:51 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 09:02:45 +0200tt1231097(~tt1231@2603:6010:8700:4a81:219f:50d3:618a:a6ee)
2024-05-26 09:04:28 +0200euphores(~SASL_euph@user/euphores)
2024-05-26 09:05:40 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 268 seconds)
2024-05-26 09:15:11 +0200xff0x(~xff0x@2405:6580:b080:900:18cf:170e:58a4:4739) (Ping timeout: 260 seconds)
2024-05-26 09:16:17 +0200acidjnk(~acidjnk@p200300d6e714dc267155b07e20dae7cf.dip0.t-ipconnect.de)
2024-05-26 09:22:19 +0200euleritian(~euleritia@ip4d16fc38.dynamic.kabel-deutschland.de) (Ping timeout: 268 seconds)
2024-05-26 09:22:32 +0200euleritian(~euleritia@ip4d16fc38.dynamic.kabel-deutschland.de)
2024-05-26 09:26:26 +0200xff0x(~xff0x@2405:6580:b080:900:9755:68f6:487e:4599)
2024-05-26 09:28:51 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 09:33:25 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 268 seconds)
2024-05-26 09:37:52 +0200lyxia(~lyxia@poisson.chat) (Quit: WeeChat 4.2.2)
2024-05-26 09:41:52 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 09:42:54 +0200machinedgod(~machinedg@d173-183-246-216.abhsia.telus.net)
2024-05-26 09:46:59 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 252 seconds)
2024-05-26 09:47:16 +0200oo_miguel(~Thunderbi@78-11-181-16.static.ip.netia.com.pl)
2024-05-26 09:51:16 +0200lyxia(~lyxia@poisson.chat)
2024-05-26 09:53:22 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 09:54:42 +0200Sgeo(~Sgeo@user/sgeo) (Read error: Connection reset by peer)
2024-05-26 09:58:47 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 264 seconds)
2024-05-26 10:00:48 +0200Nixkernal(~Nixkernal@240.17.194.178.dynamic.wline.res.cust.swisscom.ch)
2024-05-26 10:01:07 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 10:05:41 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 252 seconds)
2024-05-26 10:11:52 +0200 <tomsmeding> geekosaur: you probably made the mistake of assuming that the Num operations make any sense
2024-05-26 10:12:20 +0200tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-05-26 10:12:51 +0200 <tomsmeding> let's start with taking fromInteger out of Num and allowing implementing Num for rank0typed arrays
2024-05-26 10:12:53 +0200 <tomsmeding> *rank-typed
2024-05-26 10:13:15 +0200 <tomsmeding> (I can add 2-dimensional arrays, but what is "17" as a 2-dimensional array? Where is the size supposed to come from?)
2024-05-26 10:19:57 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 10:21:22 +0200econo_(uid147250@id-147250.tinside.irccloud.com) (Quit: Connection closed for inactivity)
2024-05-26 10:24:28 +0200Guest64(~Guest64@p200300cdb730567a31d3106a893235d7.dip0.t-ipconnect.de)
2024-05-26 10:24:36 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 268 seconds)
2024-05-26 10:26:44 +0200notzmv(~daniel@user/notzmv)
2024-05-26 10:27:06 +0200 <Leary> tomsmeding: Though `Num` indeed ought to be split up, the individual parts make plenty of sense. The missing law here is: `fromInteger` must be the (unique!) homomorphism from the Integers to the ring in question.
2024-05-26 10:31:27 +0200 <Leary> Also, ring products are a standard construction. We have monoid products up to 5-tuples, so we really ought to have the Num instances here too.
2024-05-26 10:37:36 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 10:38:46 +0200tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-05-26 10:42:48 +0200waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se)
2024-05-26 10:43:08 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 260 seconds)
2024-05-26 10:52:56 +0200machinedgod(~machinedg@d173-183-246-216.abhsia.telus.net) (Ping timeout: 260 seconds)
2024-05-26 10:53:35 +0200__monty__(~toonn@user/toonn)
2024-05-26 10:55:48 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 11:00:50 +0200mesaoptimizer(~mesaoptim@user/PapuaHardyNet) (Quit: zzz)
2024-05-26 11:02:05 +0200Guest64(~Guest64@p200300cdb730567a31d3106a893235d7.dip0.t-ipconnect.de) (Quit: Client closed)
2024-05-26 11:02:11 +0200lockywolf(~lockywolf@public.lockywolf.net) (Quit: ZNC 1.8.2 - https://znc.in)
2024-05-26 11:02:17 +0200L29Ah(~L29Ah@wikipedia/L29Ah)
2024-05-26 11:02:23 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 272 seconds)
2024-05-26 11:02:58 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 11:04:11 +0200lxsameer(~lxsameer@Serene/lxsameer)
2024-05-26 11:05:47 +0200tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-05-26 11:07:27 +0200tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-05-26 11:07:31 +0200Nixkernal(~Nixkernal@240.17.194.178.dynamic.wline.res.cust.swisscom.ch) (Quit: No Ping reply in 180 seconds.)
2024-05-26 11:07:47 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 264 seconds)
2024-05-26 11:07:49 +0200billchenchina(~billchenc@103.152.35.21)
2024-05-26 11:08:56 +0200Nixkernal(~Nixkernal@240.17.194.178.dynamic.wline.res.cust.swisscom.ch)
2024-05-26 11:12:20 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 11:16:57 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 272 seconds)
2024-05-26 11:17:39 +0200target_i(~target_i@user/target-i/x-6023099)
2024-05-26 11:18:40 +0200Tuplanolla(~Tuplanoll@91-159-69-59.elisa-laajakaista.fi)
2024-05-26 11:21:15 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 11:24:15 +0200tzh(~tzh@c-76-115-131-146.hsd1.or.comcast.net) (Quit: zzz)
2024-05-26 11:26:33 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 252 seconds)
2024-05-26 11:31:24 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 11:34:40 +0200guy(~guy@sgyl-43-b2-v4wan-169648-cust2111.vm6.cable.virginm.net)
2024-05-26 11:34:46 +0200 <guy> hi
2024-05-26 11:35:35 +0200 <guy> some of the users here are set up on a server at the uni to deliver delayed messages from my profs, are there any human users online?
2024-05-26 11:35:59 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 264 seconds)
2024-05-26 11:39:12 +0200ncfbeeps
2024-05-26 11:39:59 +0200 <guy> turing test complete!
2024-05-26 11:40:45 +0200 <guy> not that i mind talking to my profs... its just they have different constraints on how they can help me or participate in collaboration
2024-05-26 11:40:48 +0200 <ski> delayed messages from your profs ?
2024-05-26 11:40:58 +0200 <guy> but late for that!
2024-05-26 11:41:03 +0200 <guy> bit*
2024-05-26 11:41:09 +0200lockywolf(~lockywolf@public.lockywolf.net)
2024-05-26 11:41:24 +0200skidoesn't really understand the motivation for the question
2024-05-26 11:41:44 +0200 <guy> so im working on an AGI
2024-05-26 11:41:49 +0200 <guy> i actually have it complete
2024-05-26 11:41:57 +0200 <guy> im wondering where to go from here
2024-05-26 11:42:13 +0200 <guy> it has taken a long time!
2024-05-26 11:42:14 +0200 <ski> make it sound ?
2024-05-26 11:42:27 +0200 <guy> people complain if i start moaning...
2024-05-26 11:42:35 +0200 <sprout> AGI doesn't need to be sound, people aren't sound
2024-05-26 11:42:46 +0200 <guy> wait, what do you mean sound?
2024-05-26 11:42:53 +0200 <guy> it is written in a legible cannical form
2024-05-26 11:43:24 +0200 <guy> cannonical*
2024-05-26 11:44:08 +0200 <guy> i think basically i might have thought by that you meant that i should apply it to classifying phonemes
2024-05-26 11:44:21 +0200 <guy> but really it is a application agnostic
2024-05-26 11:44:44 +0200 <guy> and id prefer not to have it mussed up with any application
2024-05-26 11:44:53 +0200 <guy> especially not something with application to human control
2024-05-26 11:44:57 +0200ski. o O ( "In Sound Mind" (OST) by The Living Tombstone in 2020-06-25 at <https://www.youtube.com/watch?v=LsNd5DmbOgA&list=PL5-WT4DlkvgpZCLKZuDSgwbsY7jRBlkGw>, for a game by Modus & We Create Stuff )
2024-05-26 11:45:47 +0200 <guy> ok, if thats how you think we should speak about this?
2024-05-26 11:46:00 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker) (Excess Flood)
2024-05-26 11:46:24 +0200 <ski> i'm not too sure what exactly you have produced, tbh
2024-05-26 11:46:39 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker)
2024-05-26 11:46:43 +0200 <ski> is this some kind of LLM thing, or perhaps something else ?
2024-05-26 11:46:45 +0200 <guy> er... i certainly do not endorse this "song" you  have shared
2024-05-26 11:47:01 +0200 <guy> oh, you request the working definition for AGI
2024-05-26 11:47:16 +0200 <ncf> i request that this move to #haskell-offtopic
2024-05-26 11:47:24 +0200 <guy> an AI applied to training such an AI to get better at training itself to do this
2024-05-26 11:47:39 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker) (Excess Flood)
2024-05-26 11:47:45 +0200 <guy> ncf: yeah, the song was certainly off topic, and is not how we should discuss this.
2024-05-26 11:48:00 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 11:48:02 +0200 <ncf> no, the whole discussion
2024-05-26 11:48:47 +0200 <guy> what "whole discussion"
2024-05-26 11:48:54 +0200 <guy> basically. no
2024-05-26 11:49:03 +0200 <guy> dont start pushing people around, people end up getting banned
2024-05-26 11:49:06 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker)
2024-05-26 11:49:17 +0200 <guy> it might seem like a reasonable request, but its normally an excuse for a pile on
2024-05-26 11:49:24 +0200 <guy> this is illigal in the UK where i am residing
2024-05-26 11:49:30 +0200 <guy> ok.
2024-05-26 11:50:12 +0200 <guy> we can have code examples, and engage the community in this project if we do so responsibly
2024-05-26 11:51:58 +0200mqlnv(~tripod@47.154.25.27) (Remote host closed the connection)
2024-05-26 11:52:27 +0200guy(~guy@sgyl-43-b2-v4wan-169648-cust2111.vm6.cable.virginm.net) (Quit: Connection closed)
2024-05-26 11:53:23 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker) (Excess Flood)
2024-05-26 11:53:24 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 268 seconds)
2024-05-26 11:53:55 +0200mesaoptimizer(~mesaoptim@user/PapuaHardyNet)
2024-05-26 11:57:04 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker)
2024-05-26 11:58:16 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker) (Excess Flood)
2024-05-26 11:59:00 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 12:00:04 +0200safinaskar(~quassel@212.73.77.104)
2024-05-26 12:00:08 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker)
2024-05-26 12:02:15 +0200 <safinaskar> as well as i understand, there is some transformation, which converts normal imperative code with side effects to code written using monads (or vice-versa). how it is called?
2024-05-26 12:07:30 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 256 seconds)
2024-05-26 12:08:30 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker) (Excess Flood)
2024-05-26 12:09:19 +0200 <ski> hm, i guess something like a monadic ANF transformation
2024-05-26 12:12:09 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker)
2024-05-26 12:13:17 +0200 <safinaskar> ski: i googled "monadic ANF transformation" and got nothing
2024-05-26 12:13:25 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 12:14:21 +0200 <int-e> ANF = https://en.wikipedia.org/wiki/A-normal_form I guess
2024-05-26 12:17:47 +0200 <ncf> perhaps look at Moggi's papers on monads; i'm not sure there is a specific translation with a name
2024-05-26 12:17:52 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 260 seconds)
2024-05-26 12:18:33 +0200 <tomsmeding> also kind of related to the idea of "idiom brackets"
2024-05-26 12:20:06 +0200 <ski> yes
2024-05-26 12:20:39 +0200 <ski> i recall seeing some paper mentioning such a transformation, but alas, can't recall which. maybe it was Wadler, or maybe someone else
2024-05-26 12:20:40 +0200 <int-e> or simply expanding do-blocks
2024-05-26 12:20:56 +0200 <ncf> hmm, i didn't remember https://en.wikipedia.org/wiki/Monad_(functional_programming) looking so good
2024-05-26 12:21:01 +0200 <ski> basically, it would look a bit similar to CPS transformation
2024-05-26 12:21:09 +0200 <int-e> @undo do x <- a; let { y = f x }; c y
2024-05-26 12:21:09 +0200 <lambdabot> a >>= \ x -> let { y = f x} in c y
2024-05-26 12:22:24 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 12:24:51 +0200 <safinaskar> ncf: yeah, i think it is called "Moggi transformation"
2024-05-26 12:25:08 +0200 <int-e> Somehow it feels less like a transformation and more like specifying semantics for the imperative code to me.
2024-05-26 12:26:00 +0200 <int-e> I love keywords that have less than 10 hits on Google :)
2024-05-26 12:27:19 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 268 seconds)
2024-05-26 12:27:28 +0200 <int-e> Once you have the concept of monads and their capability to capture effects and sequencing this step becomes very shallow. No doubt many people have done that as part of other works, but does it even deserve a name?
2024-05-26 12:27:34 +0200 <ncf> yeah, i agree
2024-05-26 12:27:43 +0200 <ncf> hmm this diagram is slightly off https://en.wikipedia.org/wiki/Monad_(functional_programming)#/media/File:Multivalued_functions_with_List_monad.svg
2024-05-26 12:28:36 +0200 <ski> [| x |] = return x
2024-05-26 12:28:44 +0200 <ski> [| \x0 -> e1 |] = return (\x0 -> [| e1 |])
2024-05-26 12:28:50 +0200 <ski> [| e e0 |] = [| e |] >>= \v -> [| e0 |] >>= \v0 -> v v0
2024-05-26 12:28:53 +0200 <ski> compare with
2024-05-26 12:29:02 +0200 <ski> [| x |] = \k -> k x
2024-05-26 12:29:09 +0200 <ski> [| \x0 -> e1 |] = \k -> k (\x0 k1 -> [| e1 |] k1)
2024-05-26 12:29:12 +0200 <ski> [| e e0 |] = \k1 -> [| e |] \v -> [| e0 |] \v0 -> v v0 k1
2024-05-26 12:29:22 +0200 <ski> .. the latter being cbv CPS transformation
2024-05-26 12:30:11 +0200 <tomsmeding> both decide on an order of evaluation
2024-05-26 12:30:54 +0200 <ski> yep
2024-05-26 12:30:54 +0200 <tomsmeding> although CPS is, in some sense, nothing more than precisely that, whereas monadic lifting does a bit more, semantically
2024-05-26 12:31:00 +0200 <tomsmeding> maybe
2024-05-26 12:31:12 +0200 <ski> (and pick, say, `Cont o' as the monad ..)
2024-05-26 12:31:17 +0200 <tomsmeding> :)
2024-05-26 12:31:17 +0200 <int-e> I imagine that you can plug in Cont r as a monad to the top one to get the bottom one, so it's a generalization.
2024-05-26 12:31:33 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 12:32:10 +0200 <ski> ANF basically lifts out nested expressions into explicit `let'. for monadic, you could simply use `do' instead
2024-05-26 12:34:14 +0200 <ski> ncf : it looks weird, yea
2024-05-26 12:35:25 +0200 <tomsmeding> I feel like there is an implicit reassociation step before that 'map'
2024-05-26 12:35:41 +0200 <tomsmeding> where they go from `(cbrt [8, -8])` to `(map cbrt) [8, -8]`
2024-05-26 12:36:07 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 272 seconds)
2024-05-26 12:37:05 +0200L29Ah(~L29Ah@wikipedia/L29Ah) ()
2024-05-26 12:37:39 +0200 <ncf> https://commons.wikimedia.org/w/index.php?title=File_talk%3AMultivalued_functions_with_List_monad.…
2024-05-26 12:38:08 +0200 <tomsmeding> heh
2024-05-26 12:39:04 +0200destituion(~destituio@2a02:2121:6c3:b5b4:4960:5aad:77da:7e14)
2024-05-26 12:40:51 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 12:45:35 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 264 seconds)
2024-05-26 12:56:43 +0200 <safinaskar> i once found a toot in some mastodon server (maybe types.pl), which said something like this: "in haskell programmers are punished for using side effects. haskell was intentionally made to make side effects as painful as possible. so haskell programmers learnt that they should use side effects as little as possible. but such design is wrong. in fact, proper programming language should implement automatic Moggi transformation"
2024-05-26 12:56:53 +0200 <safinaskar> please, help me find this original too
2024-05-26 12:56:56 +0200 <safinaskar> original toot
2024-05-26 12:57:02 +0200 <safinaskar> i am unable to find it anymore
2024-05-26 12:57:16 +0200 <sprout> yah, sounds important
2024-05-26 12:58:48 +0200 <tomsmeding> the retrofitting of that idea is idiom brackets, I think
2024-05-26 12:59:16 +0200 <ncf> sounds like something conor would say
2024-05-26 12:59:45 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 13:00:01 +0200 <ski> that does sentiment does sound a bit confused
2024-05-26 13:00:06 +0200gmg(~user@user/gehmehgeh)
2024-05-26 13:00:15 +0200 <ncf> https://types.pl/@pigworker/112214856633998920
2024-05-26 13:00:52 +0200wootehfoot(~wootehfoo@user/wootehfoot)
2024-05-26 13:01:28 +0200 <sprout> it's more a sentiment than anything else. haskell wasn't engineered to make side effects painful
2024-05-26 13:01:32 +0200 <ski> (specifically "make side effects as painful as possible". not counting `unsafePerformIO' and similar, there are no side-effects, so therefore it both makes side-effects as easy as possible, and as hard as possible. (vacuously))
2024-05-26 13:01:36 +0200mrmr1553343(~mrmr@user/mrmr) (Quit: Bye, See ya later!)
2024-05-26 13:01:47 +0200 <tomsmeding> the toot is also a bit "from the category theory bubble", I'd say :p
2024-05-26 13:01:52 +0200 <sprout> maybe they are, but that's up the eye of the beholder since most haskell programmers seem to do fine
2024-05-26 13:02:23 +0200 <ski> i do agree that some notion of automatic Moggi could be useful, though
2024-05-26 13:02:25 +0200 <int-e> What does he mean by "imagine that carrier determines structure"?
2024-05-26 13:03:33 +0200 <ski> (hm, that page is blank, for me)
2024-05-26 13:03:44 +0200 <safinaskar> ncf: toot i'm talking about was made earlier that this April 2024. thanks anyway
2024-05-26 13:04:04 +0200 <ncf> int-e: probably the fact that instances have to be unique, and you "select" which instance to use by wrapping things in newtypes
2024-05-26 13:04:13 +0200 <int-e> ski: Mastodon needs Javascript unfortunately.
2024-05-26 13:04:18 +0200 <ski> what ncf said
2024-05-26 13:04:25 +0200 <ski> int-e : it's enabled
2024-05-26 13:04:32 +0200 <int-e> oh. odd.
2024-05-26 13:04:37 +0200 <ncf> maybe you need more javascript
2024-05-26 13:04:41 +0200 <tomsmeding> https://tomsmeding.com/ss/get/tomsmeding/f97paG
2024-05-26 13:05:16 +0200 <ski> (checking the source seems to work)
2024-05-26 13:05:43 +0200 <sprout> weird, I cannot seem to follow him on mastodon
2024-05-26 13:06:55 +0200 <ski> apart from (4), the criticism sounds reasonable. (4) is unclear what is meant, to me
2024-05-26 13:07:07 +0200 <sprout> ask
2024-05-26 13:07:11 +0200 <tomsmeding> ski: automatic idiom brackets around everything?
2024-05-26 13:07:28 +0200 <ski> it's not obvious to me that that's what he's suggesting
2024-05-26 13:07:32 +0200 <ncf> i think it's clear what is meant but unclear how to solve it
2024-05-26 13:07:56 +0200 <tomsmeding> ski: > The key reference is "Notions of computation and monads". The key idea is to give the semantics of a term (in an ML-like language) as a morphism in the Kleisli category of a monad. That's exactly what you do when you write a program in "monadic style". You keep a dog and bark yourself!
2024-05-26 13:08:44 +0200 <ski> some kind of take on (4) is what my "reflective syntax" is intended to cover
2024-05-26 13:08:57 +0200 <tomsmeding> it's odd to say that a language did something wrong without suggesting any alternative, so I'm going to assume that he did intend an alternative :p
2024-05-26 13:09:09 +0200 <ski> (but it's not obvious to me if he wants something akin to that, or perhaps something else entirely)
2024-05-26 13:09:12 +0200euphores(~SASL_euph@user/euphores) (Quit: Leaving.)
2024-05-26 13:09:56 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 252 seconds)
2024-05-26 13:13:56 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 13:19:25 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 256 seconds)
2024-05-26 13:22:12 +0200euphores(~SASL_euph@user/euphores)
2024-05-26 13:22:55 +0200mrmr1553343(~mrmr@user/mrmr)
2024-05-26 13:24:15 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 13:25:50 +0200rembo10(~rembo10@main.remulis.com) (Quit: ZNC 1.8.2 - https://znc.in)
2024-05-26 13:28:47 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 264 seconds)
2024-05-26 13:31:41 +0200manwithluck(manwithluc@gateway/vpn/protonvpn/manwithluck) (Ping timeout: 240 seconds)
2024-05-26 13:32:48 +0200manwithluck(manwithluc@gateway/vpn/protonvpn/manwithluck)
2024-05-26 13:32:56 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 13:37:40 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 260 seconds)
2024-05-26 13:42:02 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 13:46:52 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 268 seconds)
2024-05-26 13:49:14 +0200todi(~todi@p57803331.dip0.t-ipconnect.de) (Read error: Connection reset by peer)
2024-05-26 13:49:39 +0200rachelambda(~rachelamb@cust-95-80-25-71.csbnet.se) (Ping timeout: 268 seconds)
2024-05-26 13:50:49 +0200todi(~todi@p57803331.dip0.t-ipconnect.de)
2024-05-26 13:51:10 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 13:55:35 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 252 seconds)
2024-05-26 13:56:35 +0200rachelambda(~rachelamb@cust-95-80-25-71.csbnet.se)
2024-05-26 14:00:07 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 14:08:11 +0200tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Read error: Connection reset by peer)
2024-05-26 14:11:32 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 268 seconds)
2024-05-26 14:15:48 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 14:20:36 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 260 seconds)
2024-05-26 14:22:45 +0200elevenkb(elevenkb@thunix.net)
2024-05-26 14:23:22 +0200danza(~francesco@151.43.109.66)
2024-05-26 14:24:59 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 14:29:41 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 256 seconds)
2024-05-26 14:31:31 +0200rvalue(~rvalue@user/rvalue) (Read error: Connection reset by peer)
2024-05-26 14:32:02 +0200rvalue(~rvalue@user/rvalue)
2024-05-26 14:34:00 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 14:34:21 +0200ddellacosta(~ddellacos@ool-44c73d29.dyn.optonline.net) (Ping timeout: 268 seconds)
2024-05-26 14:35:59 +0200ocra8(ocra8@user/ocra8) (Quit: WeeChat 4.2.2)
2024-05-26 14:38:40 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 268 seconds)
2024-05-26 14:40:27 +0200remmie(ianremsen@tilde.team) (Ping timeout: 256 seconds)
2024-05-26 14:43:07 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 14:47:55 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 268 seconds)
2024-05-26 14:52:31 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 14:54:59 +0200paddymahoney(~paddymaho@pool-99-250-26-190.cpe.net.cable.rogers.com) (Ping timeout: 252 seconds)
2024-05-26 14:55:48 +0200darrik(~natch@c-9e07225c.038-60-73746f7.bbcust.telenor.se) (Ping timeout: 255 seconds)
2024-05-26 14:57:09 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 255 seconds)
2024-05-26 14:58:44 +0200Natch(~natch@c-9e07225c.038-60-73746f7.bbcust.telenor.se)
2024-05-26 15:01:48 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 15:02:15 +0200remmie(ianremsen@tilde.team)
2024-05-26 15:03:01 +0200paddymahoney(~paddymaho@pool-99-250-26-190.cpe.net.cable.rogers.com)
2024-05-26 15:03:20 +0200euleritian(~euleritia@ip4d16fc38.dynamic.kabel-deutschland.de) (Ping timeout: 268 seconds)
2024-05-26 15:03:54 +0200euleritian(~euleritia@dynamic-176-006-177-191.176.6.pool.telefonica.de)
2024-05-26 15:06:44 +0200rembo10(~rembo10@main.remulis.com)
2024-05-26 15:07:05 +0200rembo10(~rembo10@main.remulis.com) (Client Quit)
2024-05-26 15:09:08 +0200rembo10(~rembo10@main.remulis.com)
2024-05-26 15:11:18 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker) (Excess Flood)
2024-05-26 15:11:56 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 260 seconds)
2024-05-26 15:14:01 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker)
2024-05-26 15:15:22 +0200 <safinaskar> i found that toot!!!
2024-05-26 15:15:32 +0200 <safinaskar> here it is: https://types.pl/@pigworker/111320631493915615
2024-05-26 15:16:39 +0200 <safinaskar> ncf: and yes, it was Conor! thank you!
2024-05-26 15:16:42 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 15:20:01 +0200 <ski> automate, in what manner ?
2024-05-26 15:22:25 +0200 <lyxia> you may need 10 phds to find out the answer, and another 10 to actually implement it.
2024-05-26 15:23:34 +0200 <int-e> just `do` it
2024-05-26 15:25:56 +0200 <safinaskar> ski: i don't know what Conor meant. but personally I like how things done in Koka language ( https://koka-lang.github.io/koka/doc/book.html )
2024-05-26 15:26:38 +0200 <safinaskar> ski: i Koka you write code just like in usual imperative language. but under hood Koka seem to do something like Moggi translation
2024-05-26 15:27:04 +0200 <ski> effect handlers, yea
2024-05-26 15:27:17 +0200 <ski> not quite like Moggi, iiuc
2024-05-26 15:29:13 +0200 <safinaskar> (also, i kind of remember your nicknames. i think 10 years ago very same people were present in this channel)
2024-05-26 15:35:24 +0200madariaga(~madariaga@user/madariaga) (Read error: Connection reset by peer)
2024-05-26 15:37:50 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Remote host closed the connection)
2024-05-26 15:38:16 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker) (Excess Flood)
2024-05-26 15:39:58 +0200 <safinaskar> and i think i can easily implement something like koka (but their Perceus reference counting seems to be hard to implement, so i will skip it)
2024-05-26 15:41:05 +0200 <safinaskar> and koka have: 1) truly total functions, 2) failible functions, 3) possibly non-terminating functions, 4) haskell-like functions (i. e. failible AND possibly non-terminating) 5) functions with side-effects 6) etc
2024-05-26 15:41:16 +0200 <safinaskar> koka is absolutely brilliant!!
2024-05-26 15:42:08 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker)
2024-05-26 15:44:30 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 15:48:53 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 252 seconds)
2024-05-26 15:50:34 +0200Square2(~Square@user/square)
2024-05-26 15:51:39 +0200safinaskar(~quassel@212.73.77.104) ()
2024-05-26 15:51:46 +0200safinaskar(~quassel@212.73.77.104)
2024-05-26 15:54:21 +0200euleritian(~euleritia@dynamic-176-006-177-191.176.6.pool.telefonica.de) (Ping timeout: 272 seconds)
2024-05-26 15:54:45 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 15:55:52 +0200euleritian(~euleritia@dynamic-176-004-181-220.176.4.pool.telefonica.de)
2024-05-26 15:58:02 +0200 <ski> (well, i do remember your nickname, as well)
2024-05-26 15:59:27 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 268 seconds)
2024-05-26 16:00:23 +0200 <safinaskar> ski: cool :)
2024-05-26 16:00:52 +0200 <safinaskar> somewhere in 2014 i tried to write my prover in haskell. and it is still unfinished and buggy :(
2024-05-26 16:01:13 +0200 <safinaskar> i still have no time to implement proper de bruijn indices
2024-05-26 16:02:54 +0200 <safinaskar> also i remember someone in this channel told about his idea for idiom brackets long time ago. this brackets didn't exist in that time. yet they seem to be available now (in form of a plugin)
2024-05-26 16:04:06 +0200 <ski> perhaps you're thinking of
2024-05-26 16:04:15 +0200 <ski> @hackage applicative-quoters
2024-05-26 16:04:15 +0200 <lambdabot> https://hackage.haskell.org/package/applicative-quoters
2024-05-26 16:04:38 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker) (Excess Flood)
2024-05-26 16:04:47 +0200 <ski> .. or it was me talking about my idea, which is inspired by idiom brackets, amongst other things
2024-05-26 16:05:08 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker)
2024-05-26 16:08:59 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker) (Excess Flood)
2024-05-26 16:09:22 +0200 <safinaskar> i just asked Conor on mastodon what he thinks about koka. he said: "it’s the right way out of this mess."
2024-05-26 16:12:05 +0200Square2(~Square@user/square) (Ping timeout: 240 seconds)
2024-05-26 16:12:11 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 16:12:38 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker)
2024-05-26 16:17:24 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 256 seconds)
2024-05-26 16:17:44 +0200justsomeguy(~justsomeg@user/justsomeguy) (Ping timeout: 260 seconds)
2024-05-26 16:27:09 +0200 <safinaskar> also i recently wrote post about how bad de brujin indices are. https://safinaskar.writeas.com/this-is-why-you-should-never-use-de-bruijn-indices-especially-if-yo…
2024-05-26 16:39:53 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 16:45:35 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 264 seconds)
2024-05-26 16:47:17 +0200danza(~francesco@151.43.109.66) (Remote host closed the connection)
2024-05-26 16:47:42 +0200danza(~francesco@151.43.109.66)
2024-05-26 16:49:19 +0200danza(~francesco@151.43.109.66) (Remote host closed the connection)
2024-05-26 16:51:33 +0200mc47(~mc47@xmonad/TheMC47)
2024-05-26 16:55:02 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker) (Excess Flood)
2024-05-26 16:55:41 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker)
2024-05-26 16:57:19 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker) (Excess Flood)
2024-05-26 16:57:58 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker)
2024-05-26 16:58:38 +0200euleritian(~euleritia@dynamic-176-004-181-220.176.4.pool.telefonica.de) (Read error: Connection reset by peer)
2024-05-26 16:58:57 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 16:58:58 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker) (Excess Flood)
2024-05-26 16:59:03 +0200euleritian(~euleritia@dynamic-176-004-181-220.176.4.pool.telefonica.de)
2024-05-26 16:59:39 +0200TheCoffeMaker(~TheCoffeM@user/thecoffemaker)
2024-05-26 17:02:19 +0200Square2(~Square@user/square)
2024-05-26 17:04:14 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 252 seconds)
2024-05-26 17:07:43 +0200 <mauke> "Programming languages, such as Haskell and Agda, have a feature: they allow us to copy values very easily" sounds backwards to me
2024-05-26 17:07:49 +0200 <mauke> conceptually, Haskell never copies anything
2024-05-26 17:12:16 +0200 <kaol> It's one way to look at immutable values.
2024-05-26 17:16:30 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 17:20:59 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 264 seconds)
2024-05-26 17:27:53 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 17:30:06 +0200bjorkint0sh(~bjork@2600:1700:5400:c80:f334:68eb:cbb4:99fd)
2024-05-26 17:31:34 +0200actfulCitrusT(~al@2a02:8012:87a6:0:fbe0:6116:6e30:e047)
2024-05-26 17:32:12 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 256 seconds)
2024-05-26 17:32:29 +0200bjorkintosh(~bjork@user/bjorkintosh) (Ping timeout: 240 seconds)
2024-05-26 17:33:02 +0200safinaskar(~quassel@212.73.77.104) ()
2024-05-26 17:33:54 +0200AlexNoo(~AlexNoo@5.139.233.209) (Read error: Connection reset by peer)
2024-05-26 17:34:19 +0200AlexNoo(~AlexNoo@5.139.233.209)
2024-05-26 17:35:08 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 17:35:31 +0200ocra8(ocra8@user/ocra8)
2024-05-26 17:36:00 +0200tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-05-26 17:39:52 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 260 seconds)
2024-05-26 17:44:10 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 17:48:47 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 252 seconds)
2024-05-26 17:51:26 +0200mc47(~mc47@xmonad/TheMC47) (Remote host closed the connection)
2024-05-26 17:53:11 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 17:57:08 +0200Square2(~Square@user/square) (Ping timeout: 260 seconds)
2024-05-26 17:58:47 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 264 seconds)
2024-05-26 18:03:23 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 18:05:33 +0200CiaoSen(~Jura@2a05:5800:2b6:2100:e6b9:7aff:fe80:3d03)
2024-05-26 18:06:12 +0200tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-05-26 18:07:06 +0200robobub(uid248673@id-248673.uxbridge.irccloud.com)
2024-05-26 18:08:23 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 264 seconds)
2024-05-26 18:11:56 +0200hammond(proscan@user/hammond2)
2024-05-26 18:12:26 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 18:12:49 +0200 <hammond> is there optimizations that can be done with haskell compiler?
2024-05-26 18:14:23 +0200 <Rembane> hammond: Yes! Give GHC the option -O2 to make it optimize. How come you're asking?
2024-05-26 18:15:27 +0200 <hammond> im reading learning about compilers just now and i was wondering. seems like a dauthing task to optimize code.
2024-05-26 18:16:21 +0200 <tomsmeding> if you are using cabal, the default is -O1, which is enough for most purposes
2024-05-26 18:16:30 +0200 <tomsmeding> so in that case you don't even have to specify anything :)
2024-05-26 18:16:32 +0200 <hammond> Rembane: Does haskell go to c first and then optimize further with something like gcc
2024-05-26 18:16:39 +0200machinedgod(~machinedg@d173-183-246-216.abhsia.telus.net)
2024-05-26 18:16:46 +0200 <tomsmeding> GHC did that in the past, not anymore
2024-05-26 18:16:58 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 256 seconds)
2024-05-26 18:17:10 +0200 <tomsmeding> one can build GHC in such a way that it uses LLVM in the end to further optimise and assemble your code
2024-05-26 18:17:19 +0200 <tomsmeding> but GHC has many good optimisations built-in :)
2024-05-26 18:17:37 +0200 <hammond> nice to know.
2024-05-26 18:18:11 +0200 <tomsmeding> as an idea for a very simple, but important one: if you have `case Constr x y of { ... ; Constr a b -> E ; ... }`, then this can be simplified to `E` with a and b replaced by x and y, respectively
2024-05-26 18:18:16 +0200euphores(~SASL_euph@user/euphores) (Quit: Leaving.)
2024-05-26 18:18:22 +0200 <tomsmeding> this is "case of known constructor"
2024-05-26 18:19:15 +0200 <tomsmeding> if you have `let x = A in B` where x is used only once in B, then you can replace that x by A and move the let binding (this is "inlining")
2024-05-26 18:19:34 +0200 <tomsmeding> inlining can lead to more occurrences of case-of-known-constructor
2024-05-26 18:19:44 +0200 <hammond> i see.
2024-05-26 18:19:45 +0200CiaoSen(~Jura@2a05:5800:2b6:2100:e6b9:7aff:fe80:3d03) (Quit: CiaoSen)
2024-05-26 18:19:46 +0200 <tomsmeding> in general, optimisations typically work well together, where one enables more uses of the other
2024-05-26 18:19:58 +0200 <tomsmeding> compilers have a whole arsenal of these :)
2024-05-26 18:20:48 +0200 <hammond> tomsmeding: why does it feel like haskell is harder to optimize than something like c. I cant explain why i feel this but it's there.
2024-05-26 18:20:56 +0200joeyadams(~joeyadams@38.48.105.67)
2024-05-26 18:21:08 +0200 <tomsmeding> there are different things that you can do, because the language works differently
2024-05-26 18:21:13 +0200 <tomsmeding> it's not really inherently easier or harder
2024-05-26 18:21:19 +0200 <hammond> yeah
2024-05-26 18:21:32 +0200 <tomsmeding> some things are much easier to _analyse_ about a haskell program, because of the purity
2024-05-26 18:21:50 +0200 <tomsmeding> a C compiler must worry that after a function call, all kinds of variables, arrays, etc. may now suddenly have different values
2024-05-26 18:22:11 +0200 <Leary> Seems much easier in Haskell to me. A lot of it is just compile-time evaluation.
2024-05-26 18:22:11 +0200 <hammond> tomsmeding: would there be cases where the compiler tries to optimize and actually makes it harder? say if your cpu doesn't have enough L1 cache.
2024-05-26 18:22:20 +0200 <tomsmeding> hence must re-load things from memory etc; if it can analyse the function to not touch those arrays, then it can avoid those additional memory accesses
2024-05-26 18:22:23 +0200euphores(~SASL_euph@user/euphores)
2024-05-26 18:22:27 +0200 <tomsmeding> in a pure language, this whole point is moot
2024-05-26 18:22:38 +0200 <hammond> i see
2024-05-26 18:22:47 +0200 <tomsmeding> but then, purely functional languages map less directly to the hardware, so there is more work to do in making them practically efficient
2024-05-26 18:22:55 +0200 <tomsmeding> the difficulty is in different places
2024-05-26 18:23:01 +0200Rodney_(~Rodney@176.254.244.83)
2024-05-26 18:23:12 +0200 <tomsmeding> Leary: the optimisations in Core are easier perhaps
2024-05-26 18:23:26 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 18:23:37 +0200 <tomsmeding> but what about thinking up STG, its semantics, and the Core->STG->Cmm->Asm translations?
2024-05-26 18:23:58 +0200 <tomsmeding> LLVM IR may have a lot of operations, and may be a "big" language in comparison, but conceptually it's quite simple
2024-05-26 18:23:58 +0200puke(~puke@user/puke) (Remote host closed the connection)
2024-05-26 18:24:19 +0200puke(~puke@user/puke)
2024-05-26 18:24:25 +0200 <tomsmeding> "take assembly and make it a bit more high level"
2024-05-26 18:24:44 +0200 <tomsmeding> STG is fundamentally different from both Core and the imperative CPU execution model
2024-05-26 18:25:22 +0200puke(~puke@user/puke) (Max SendQ exceeded)
2024-05-26 18:25:32 +0200Sgeo(~Sgeo@user/sgeo)
2024-05-26 18:25:56 +0200 <hammond> well let me ask you this since im still a beginner, does -02 act like -O3 in gcc where some new bug arrises because of the optimization ? you're essentially making the final code unsafer right?
2024-05-26 18:26:17 +0200 <tomsmeding> is -O3 in gcc unsound?
2024-05-26 18:26:32 +0200 <tomsmeding> ("unsound", in this situation means that it may change the meaning of the code)
2024-05-26 18:26:37 +0200 <tomsmeding> if so that would be a gcc bug :p
2024-05-26 18:26:50 +0200puke(~puke@user/puke)
2024-05-26 18:27:04 +0200 <EvanR> making floating point math faster, while breaking it
2024-05-26 18:27:04 +0200 <tomsmeding> -ffast-math is a common C compiler flag that does change the meaning of code for the purpose of making some things faster
2024-05-26 18:27:13 +0200 <tomsmeding> -O3 != -ffast-math
2024-05-26 18:27:47 +0200 <tomsmeding> gcc -O3 is just "try harder and take more time, potentially making your code a bit slower if gcc makes some wrong assumptions about hot/cold code or hardware"
2024-05-26 18:27:50 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 252 seconds)
2024-05-26 18:27:55 +0200 <tomsmeding> ghc -O2 is similar
2024-05-26 18:28:12 +0200 <tomsmeding> if any -O flag changes the code's meaning, that's a bug in the compiler
2024-05-26 18:28:50 +0200 <tomsmeding> (0 != O, if they look the same to you you should use a better font :) )
2024-05-26 18:29:44 +0200 <tomsmeding> ghc -O1 is cabal's default and is like gcc -O2, the "standard optimisation set"
2024-05-26 18:30:10 +0200 <tomsmeding> ghc -O2 is like gcc -O3, "I want more performance and am willing to 1. spend more compile time and 2. benchmark and profile to see if it really helps"
2024-05-26 18:30:46 +0200 <hammond> i see. well i was looking at loop-unrolling for example in gcc, and how it can make it slower for some processors.
2024-05-26 18:30:55 +0200 <tomsmeding> that's an example
2024-05-26 18:31:07 +0200 <hammond> yeah i read -O3 was buggy back in the beginning.
2024-05-26 18:31:08 +0200 <tomsmeding> gcc -O3 may be more aggressive there, which may help sometimes and not help other times
2024-05-26 18:31:20 +0200 <tomsmeding> probably, but many things are buggy when software projects are young :)
2024-05-26 18:31:21 +0200tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-05-26 18:31:37 +0200 <hammond> heh ok.
2024-05-26 18:32:27 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 18:38:11 +0200euleritian(~euleritia@dynamic-176-004-181-220.176.4.pool.telefonica.de) (Read error: Connection reset by peer)
2024-05-26 18:38:25 +0200euleritian(~euleritia@tmo-118-108.customers.d1-online.com)
2024-05-26 18:41:00 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 260 seconds)
2024-05-26 18:41:02 +0200Rodney_(~Rodney@176.254.244.83) (Ping timeout: 252 seconds)
2024-05-26 18:45:20 +0200euleritian(~euleritia@tmo-118-108.customers.d1-online.com) (Ping timeout: 268 seconds)
2024-05-26 18:46:32 +0200euleritian(~euleritia@dynamic-176-004-181-220.176.4.pool.telefonica.de)
2024-05-26 18:46:45 +0200BigKozlowski(~BigKozlow@194.5.60.133)
2024-05-26 18:51:30 +0200BigKozlowski(~BigKozlow@194.5.60.133) (Ping timeout: 268 seconds)
2024-05-26 18:52:16 +0200Rodney_(~Rodney@176.254.244.83)
2024-05-26 18:56:06 +0200BigKozlowski(~BigKozlow@194.5.60.133)