|
🦋 Welcome to the IRC channel of the core developers of the Raku Programming Language (raku.org #rakulang). This channel is logged for the purpose of history keeping about its development | evalbot usage: 'm: say 3;' or /msg camelia m: ... | Logs available at irclogs.raku.org/raku-dev/live.html | For MoarVM see #moarvm Set by lizmat on 8 June 2022. |
|||
|
01:07
ilogger2 joined
|
|||
| japhb | Is there a way to ask the *static* optimizer to inline a sub call? | 01:41 | |
| I have some really code that is built up from a lot of small routines just as a matter of both DRY and complexity management, but I'd like the whole thing to be flattened as much as possible in the compiled code. | 01:43 | ||
| (Because a lot of those small routines are called from loops, within branch trees, or both) | |||
| timo | have you checked yet how the inlining success rate is? there's a handy -M that liz came up with that you can just put on your raku command to spit out a summary of inlining at the end | 02:12 | |
| i think it's -MIL or -MSIL or so? | |||
| yeah it's -MSIL | |||
| i believe the parts of the static optimizer that were for statically inlining stuff were removed because moarvm's runtime specializer was better at the job anyway, and before that i think it might only have been active for subs with only native arguments like int num or str, so a lot of our operators | 02:16 | ||
| japhb | timo: Will that show the inlining results *for a particular routine*? | 03:07 | |
| Meanwhile: "Gee, looks like I need a new str primitive, which is almost certainly going to be a bottleneck. Guess I'll be jumping into NQP land again ..." | 03:09 | ||
| timo | it shows for all inlining attempts whether they worked or were prevented by something, and the attempts include everything from the compilation stage through execution | 03:17 | |
| japhb | Hmmm, OK, thanks timo | 03:47 | |
|
08:17
guifa left
|
|||
| timo | of course it isn't ideal that you can't say up front for sure that a sub will get inlined where-ever you call it, and you have to rely on the specializer to make the decision that it's worth it, and our heuristics aren't exactly highly sophisticated | 09:50 | |
| disbot7 | <grizzlysmit> sorry just saw your post I have experienced this in Terminator it always worked before, hmm just tried in gnome terminal same result | 10:09 | |
| <grizzlysmit> will try others and I'll test other Ubuntu versions in KVM see if that works | 10:10 | ||
| <grizzlysmit> oK same result in xterm | 10:26 | ||
| timo | github.com/tony-o/raku-fez/blob/ma...od#L18-L26 - getpass is relatively simple, it asks stty for the current options, then it turns the echo option off, reads a line from stdin, then gives stty the same thing that it outputted at the beginning | 10:32 | |
| can you run these commands yourself? | 10:34 | ||
| does `stty $(stty -g)` work or give an error? | |||
| and what about `stty 6506:5:f00bf:8a3b:3:1c:7f:15:4:0:1:0:11:13:1a:0:12:f:17:16:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0` which is the same thing it tried to do when it got that error | 10:35 | ||
| i mean, it looks like it's supposed to just tell you "invalid argument" but why | 10:36 | ||
| github.com/uutils/coreutils/issues...3425339084 well that's just weird | 10:37 | ||
| i have no idea what uutils is | 10:38 | ||
| are you using nixos or something? | |||
| uutils is a rewrite of gnu coreutils in rust it seems like | 10:39 | ||
| disbot7 | <grizzlysmit> $ stty $(stty -g) stty: invalid argument '6506:5:f00bf:8a3b:3:1c:7f:15:4:0:1:0:11:13:1a:0:12:f:17:16:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0' $ stty 6506:5:f00bf:8a3b:3:1c:7f:15:4:0:1:0:11:13:1a:0:12:f:17:16:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0 stty: invalid argument '6506:5:f00bf:8a3b:3:1c:7f:15:4:0:1:0:11:13:1a:0:12:f:17:16:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0' yeah Ubuntu 24.10 uses a new rewrite of core utils written in rust wonder if | 10:44 | |
| that's it looks like I need to invesegate that | |||
| timo | it sounds like that's it, and that's kind of hilarious but also infuriating | 10:45 | |
| disbot7 | <grizzlysmit> yeah I'll gather more data and submit a bug | 10:48 | |
| timo | well the bug is already submitted and fixed | 10:52 | |
| do you have a `gnustty` binary on your system already? | 11:06 | ||
| disbot7 | <grizzlysmit> yup it still works on an old copy of 25.04 | ||
| <grizzlysmit> gnustty I will ook | 11:07 | ||
| <grizzlysmit> look* | |||
| timo | maybe rakudo should just re-execute every shell command that fails a second time with a "gnu" in front of the program name to work around systems that have one set of broken core utils and a second set of working coreutils with different names | ||
| disbot7 | <grizzlysmit> yes $ gnustty speed 38400 baud; line = 0; iutf8 | 11:08 | |
| timo | uutils version 0.5.0 was tagged on their github repo december 14th, is that version not available in ubuntu yet? | 11:10 | |
| disbot7 | <grizzlysmit> **<timo>** maybe rakudo should just re-execute every shell command that fails a second time with a "gnu" in front of the program name to work around systems that have one set of broken core utils and a second set of working coreutils with different names ah OK that | ||
| <grizzlysmit> might work do you have a work around ??? | |||
| timo | no that is an incredibly bad idea and should never even be considered, to be clear i was being sarcastic | 11:11 | |
| disbot7 | <grizzlysmit> OK | ||
| <grizzlysmit> is there a soln I can use ??? | 11:12 | ||
| timo | bugs.launchpad.net/ubuntu/+source/...comments/9 | ||
| this will use the gnustty binary to provide the stty command on your system | |||
| this will also fix other programs that are trying to use stty with -g | |||
| such as, apparently, ecryptfs. wow. | 11:13 | ||
| looks like there is no upload to ubuntu yet of the 0.5.0 version, and they haven't got 0.4.0 or 0.3.0 either | 11:14 | ||
| disbot7 | <grizzlysmit> thanks that worked | ||
| timo | that's good to hear | ||
| sorry i'm a little bit ... flabbergasted | |||
| is this just a replay of archlinux's python3 ... "situation"?! | 11:15 | ||
| disbot7 | <grizzlysmit> I am unfamiliar with that situation | 11:21 | |
| timo | archlinux switched /usr/bin/python from providing a python 2 to a python 3 by default much much much earlier than pretty much every other distribution, and since 2 and 3 had syntax incompatibilities, most notably `print "hello"` becoming a syntax error in favor of `print("hello")` | 11:27 | |
| so just a vast amount of programs and scripts wouldn't be able to run unchanged on an archlinux system | 11:28 | ||
| disbot7 | <grizzlysmit> ah ok the trouble with going to early, I learned python3 first then had to learn 2 as it was too early | 12:50 | |
| timo | the "from __future__ import xyz" stuff was useful | 12:51 | |
| Geth | rakudo/main: c7e41bd8ec | (Elizabeth Mattijsen)++ | 2 files Make -MSIL cleaner by excluding any core BBs Adds a :skip-core named argument to the SIL subroutine that will execute a "use Test" and record the BBs seen from that. Those BBs will then not be reported. The logic behind executing "use Test" is to execute at least part ... (15 more lines) |
13:05 | |
| lizmat | timo: ^^ " it shows for all inlining attempts whether they worked or were prevented by something, and the attempts include everything from the compilation stage through execution" triggered me | 13:07 | |
| timo | ha! :) | 13:08 | |
| interesting | |||
|
13:34
librasteve_ left
16:01
nuno joined
16:09
nuno left
17:50
rakkable left
17:51
rakkable joined
18:34
gfldex left
18:36
gfldex joined
20:26
guifa joined
23:25
ShimmerFairy left
|
|||