Perl 6 - the future is here, just unevenly distributed

IRC log for #moarvm, 2017-02-21

| Channels | #moarvm index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:22 pyrimidine joined #moarvm
01:39 BenGoldberg joined #moarvm
02:14 pyrimidine joined #moarvm
04:07 geekosaur joined #moarvm
04:11 pyrimidi_ joined #moarvm
04:28 nebuchadnezzar joined #moarvm
06:54 brrt joined #moarvm
08:06 pyrimidine joined #moarvm
08:13 brrt joined #moarvm
08:22 zakharyas joined #moarvm
08:37 brrt \o #moarvm
08:52 brrt joined #moarvm
09:06 agentzh joined #moarvm
09:38 jnthn o/
09:38 yoleaux2 02:16Z <MasterDuke> jnthn: i've updated https://github.com/rakudo/rakudo/pull/1018. it now builds for the JVM, and ./perl6-j -e 'say "hi"' runs fine, but a `make install` fails and i can't run the spectests. here's a gist of the output i get https://gist.github.com/MasterDuke17/2c8fbc294f3c9defcf370de046af1331. tied adding some debug statements, nothing jumping out at me. any suggestions?
09:49 brrt joined #moarvm
10:05 brrt joined #moarvm
10:18 pyrimidine joined #moarvm
10:26 ggoebel joined #moarvm
10:28 jnthn A new SEGV: https://rt.perl.org/Ticket/Display.html?id=130825
10:33 brrt :'-(
10:33 jnthn Granted not on anything anyone would sensibly be doing :)
10:59 brrt joined #moarvm
11:23 brrt joined #moarvm
11:35 pyrimidine joined #moarvm
12:12 Guest67605 joined #moarvm
12:17 Guest67605 left #moarvm
12:50 pyrimidine joined #moarvm
13:54 IOninja So... "serving from the shadows" is the MoarVM slogan... or was that a joke one?
13:56 brrt not sure. MoarVM isn't much marketed at all
13:57 jnthn That was kinda deliberate. :)
13:58 jnthn "Only get a userbase besides NQP/Rakudo by accident" :P
13:59 jnthn (No, that's not a slogan suggestion :P)
14:02 * brrt nods
14:02 brrt on the other hand
14:02 brrt it might be possible to get more contributor interest with more active marketing
14:04 IOninja Well, I'm going with "serving from the shadows"
14:04 IOninja If only because it fits very nicely in this space I have for it :)
14:21 agentzh joined #moarvm
14:26 geekosaur joined #moarvm
14:35 pyrimidine joined #moarvm
16:09 pyrimidine joined #moarvm
16:20 pyrimidine joined #moarvm
16:27 agentzh joined #moarvm
17:14 pyrimidine joined #moarvm
17:16 timotimo oops
17:17 timotimo i accidentally a marketing
17:17 jnthn Ooops! Quick, how can we make sure nobody knows?!
17:18 IOninja :)
17:20 IOninja I didn't do any logos last Friday. Didn't have... uh... "inspiration"
17:20 dogbert17 AddressSanitizer can not provide additional info wrt RT #130825.
17:20 synopsebot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=130825
17:20 dogbert17 #0 0xb5699a06 in search_frame_handlers.isra.7.constprop.15 /home/dogbert/repos/rakudo/nqp/MoarVM/src/core/exceptions.c:123
17:20 dogbert17 #1 0xb569b0c9 in search_for_handler_from /home/dogbert/repos/rakudo/nqp/MoarVM/src/core/exceptions.c:153
17:20 dogbert17 #2 0xb56a17d5 in MVM_exception_throwpayload /home/dogbert/repos/rakudo/nqp/MoarVM/src/core/exceptions.c:616
17:21 dogbert17 FWIW
17:29 jnthn Backtrace fits the code that crashes, though. Will try and look at that one tomorrow.
17:34 dogbert17 cool, looked through the SEGV list on RT, several cases are no longer SEGV's according to the comments, some I can't reproduce while others seem to predate MoarVM
17:35 dogbert17 only a couple were easy to reproduce
17:45 IOninja What do you think of dragons?
17:45 timotimo they have a relation to compilers
17:46 IOninja hehe
17:46 IOninja the book yeah
17:49 IOninja Thinking of one of "M"s being a stylized dragon with the tail kinda flipping and its end being part of the "V".
17:50 timotimo .o( the dragon and the butterfly )
17:50 IOninja tried with a pre-made dragon and pretty much ended up with "oar" VM :) Need my watson pad... and to remember how to draw again.
18:02 pyrimidine joined #moarvm
18:33 jnthn .oO( oar VM has missed the boat )
18:36 IOninja :D
19:15 pyrimidine joined #moarvm
19:24 pyrimidine joined #moarvm
20:11 pyrimidine joined #moarvm
20:28 dogbert17 jnthn, timotimo: moronic C question. Is it certain that 'result' is set to a value at https://github.com/MoarVM/MoarVM/blob/master/src/spesh/dump.c#L286
20:30 moritz I don't think so
20:30 dogbert17 .oO
20:30 jnthn No
20:30 moritz if the rest of the logic is right, I'd unify the if (sc) and if (result) to a single branch
20:31 jnthn Or at the very least just NULL it beforehand.
20:31 moritz ah no, won't work if MVM_sc_try_get_object returns 0
20:31 moritz right, that's probably the safer approach
20:32 dogbert17 so locals are set to zero/NULL
20:32 jnthn In C, locals are - unless you assign to them - potentially anything
20:32 jnthn So need to be NULL'd/zeroed explicitly
20:32 dogbert17 jnthn sry didn't read what you wrote
20:33 dogbert17 for fun I ran a tool call cppcheck on the Moar codebase
20:34 dogbert17 it didn't find much and I don't know if everything it DID find is correct (or false positives)
20:34 dogbert17 this was one of the (very few) complaints
20:36 dogbert17 should I PR this?
20:38 moritz yes!
20:39 dogbert17 I can gist the list if anyone with more knowledge of C wants to take a look
20:40 jnthn Feel free to do that also :)
20:40 moritz my C knowledge is very limited, but I can take a peek
20:42 dogbert17 https://gist.github.com/dogbert17/a32e2ebdc3fee069e173f00141417789
20:43 dogbert17 will be interesting to see/hear how many of those are false positives
20:45 moritz the first one seems genuine
20:46 moritz dogbert17: did you run it against current master?
20:47 dogbert17 2017-02
20:47 moritz that explains why some line numbers seem to be off
20:47 pyrimidine joined #moarvm
20:49 dogbert17 some line numbers look a bit strange to me as well
20:51 moritz the leak of values in nativecall_libffi.c might be real, dunno
20:53 * moritz doesn't understand enough of moarvm's memory management
20:53 moritz the leaks in the string functions seem to be false positive
20:53 moritz ((MVMArray *)out)->body.slots.u32 = (MVMuint32 *) result;
20:53 moritz nope, result doesn't leak here
20:54 dogbert17 the nativecall thing looked strange to me as well
20:55 Geth ¦ MoarVM: 06c5798724 | (Moritz Lenz)++ | 2 files
20:55 Geth ¦ MoarVM: Initialize some variables
20:55 Geth ¦ MoarVM:
20:55 Geth ¦ MoarVM: found by dogbert17++ through cppcheck
20:55 Geth ¦ MoarVM: review: https://github.com/MoarVM/MoarVM/commit/06c5798724
20:55 moritz I don't think I'm doing anything risky there
20:56 moritz dogbert17: do you want me to fix the one in spesh.c too, or are you doing the PR?
20:56 dogbert17 please do
20:57 Geth ¦ MoarVM: 16eac84994 | (Moritz Lenz)++ | src/spesh/dump.c
20:57 Geth ¦ MoarVM: Initialize another variable
20:57 Geth ¦ MoarVM:
20:57 Geth ¦ MoarVM: again, found by dogbert17++ through cppcheck
20:57 Geth ¦ MoarVM: review: https://github.com/MoarVM/MoarVM/commit/16eac84994
20:58 moritz dogbert17: what was your process for plugging cppcheck into the build?
20:58 pyrimidine joined #moarvm
20:59 dogbert17 I just ran 'cppcheck . 2> err.txt' from within /home/dogbert/repos/rakudo/nqp/MoarVM/src. Not sure if it's the right way to do it though.
21:01 moritz dogbert17: ah, nice. I thought it might require more integration with the build system
21:03 dogbert17 the version included in my Linux dist is 1.61 which is a bit old I think, the newer versions might be better
21:04 moritz ubuntu ships with 1.72
21:05 moritz [src/core/interp.c:110]: (error) Expression 'op=*(MVMuint16*)(cur_op),cur_op+=2,op' depends on order of evaluation of side effects
21:05 moritz looks genuine; don't know how picky compilers are
21:05 moritz [src/profiler/log.c:195]: (error) Possible null pointer dereference: sfs
21:06 moritz that looks also genuine
21:06 dogbert17 uh oh
21:07 moritz ah no, there's a conditional initialization above it that's always run on the first iteration of the loop it's in
21:08 moritz but I understand why the tool doesn't comprehend that :-)
21:08 dogbert17 perhaps you're underestimating your knowledge of C :)
21:10 moritz not really; I'm just not scared of reading code where I'm not sure I understand it all
21:11 dogbert17 for me the tool wasn't blazing fast
21:12 * dogbert17 is interested in the upcoming Ryzen CPU's
21:13 moritz faster than eyeballing the same amount of code :-)
21:13 dogbert17 :-)
21:13 moritz I'm kinda amazed that it manages to produce somewhat useful results without any up-front configuration
21:14 moritz if you think about how much configuration moarvm's build system does...
21:14 dogbert17 it's impressive indeed
21:16 dogbert17 are you getting a larger list with the newer version?
21:16 timotimo i should run coverity over moar again
21:16 dogbert17 timotimo, how's your C fu?
21:17 timotimo it's all right
21:17 dogbert17 what is your opinion on [core/nativecall_libffi.c:420]: (error) Memory leak: values
21:17 timotimo i don't have something on that line
21:18 timotimo oh, that's just the end of the block
21:18 dogbert17 it seem as if values is allocated but never used (to my untrained eyes)
21:19 timotimo yeah, looks the same way to me
21:19 timotimo maybe it was copypasted from nativecall_invoke
21:19 timotimo which uses macros to do stuff with values
21:19 dogbert17 ah the dreaded copy 'n paste error
21:20 timotimo it was added in one gigantic commit where libffi support was added
21:27 timotimo in 3h i'll've finished downloading the coverity sdk thingie
21:28 dogbert17 that sounds kinda slow
21:31 timotimo almost 500mb
21:31 timotimo and someting's wrong with the connection i guess
21:31 timotimo 11 mins left
21:52 dogbert17 is it Coverity Scan you're downloading?
21:52 timotimo yup
21:52 dogbert17 cool
22:08 camelia joined #moarvm
22:09 MasterDuke joined #moarvm
22:14 timotimo i forgot how to get git metadata into the results
22:15 dogbert17 do you find anything or haven't you started yet?
22:19 timotimo haven't started yet
22:27 timotimo done. now we just have to wait.
22:27 timotimo well, and i have to upload the thing
22:27 timotimo which is 7 megs big and internet connections in germany always have super shitty upstream bandwidth
22:27 samcv good day everybody
22:28 timotimo greetings samcv
22:29 samcv :)
22:29 timotimo 60%
22:31 timotimo Last Build Status: In-queue. Your build is in the queue to be analyzed. There are 25 builds ahead of it.
22:32 samcv we using cppcheck?
22:32 timotimo that's cppcheck
22:32 samcv nice
22:33 timotimo er
22:33 timotimo i meant to say
22:33 timotimo that's coverity
22:33 samcv kk
22:36 timotimo the defect density has gone down even more
22:36 timotimo https://scan.coverity.com/projects/paultcochrane-moarvm
22:57 timotimo we're too good.
22:57 timotimo if y'all give me an email address i'll forward the details that coverity sent me
22:58 timotimo i can just gist it!
22:58 timotimo https://gist.github.com/timo/aa786e6fe415b6bb21c176659391e841
22:59 timotimo why in the everliving fuck does it report the exact same issue on the exact same line four times?
23:08 dogbert17 do you see anything particularly nasty?
23:09 timotimo i have to fire up the analysis frontend
23:09 timotimo huh, something must have gone wrong
23:09 timotimo i only see a single defect, and it's one i marked "fix submitted
23:09 timotimo " so what the hell?
23:11 timotimo gotta look further into this later, for now i gotta go AFK
23:11 timotimo sign in to scan.coverity.com with your github users and request access so you can help out
23:18 dogbert17 done
23:26 pyrimidine joined #moarvm
23:33 samcv how does it know if there's a missing break or not
23:34 samcv what if it is intentional? how does it discern?
23:35 geekosaur traditionally one includes a comment /*FALLTHROUGH*/, because that's what AT&T lint used
23:36 geekosaur fwiw
23:37 samcv ah kk. makes sense
23:37 geekosaur that said, dataflow analysis can make a guess that if most paths that break; do some initialization and any blocks that don't are followed by one that does, then a block that does that initialization but doesn't break; is a likely bug
23:38 samcv yeah thta last one isn't a bug
23:40 samcv i'll fix that warning though
23:49 samcv geekosaur, do i have to make it all caps though
23:49 geekosaur that I couldn't say. AT&T lint required it that way (both caps and lack of spaces), but we're a long way from 1970s heuristic analyzers :)
23:49 samcv yeah
23:50 geekosaur might do better to contact the person running coverity and ask them to check the manual
23:50 Geth ¦ MoarVM: samcv++ created pull request #539: Streamline some switches and try to suppress Coverity warnings
23:50 Geth ¦ MoarVM: review: https://github.com/MoarVM/MoarVM/pull/539
23:50 geekosaur unless you can find a copy of it online
23:59 BenGoldberg joined #moarvm

| Channels | #moarvm index | Today | | Search | Google Search | Plain-Text | summary