Camelia, the Perl 6 bug

IRC log for #parrot, 2012-09-28

Parrot | source cross referenced

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

All times shown according to UTC.

Time Nick Message
00:03 pmichaud I just discovered something
00:03 pmichaud earlier versions of Parrot had stdout as unbufferred
00:03 pmichaud *unbuffered
00:06 pmichaud i.e., completely unbuffered
00:06 pmichaud 4.8.0 is buffering stdout
00:06 pmichaud (and that's why the logic didn't exist in the old system)
00:09 pmichaud https://gist.github.com/3797212   # sample program
00:10 pmichaud when I run that program under 4.6.0, the "abc: " appears immediately, followed by "def" two seconds later.
00:10 pmichaud When I run the program under 4.8.0, "abc: def" appears 2 seconds after the program starts.
00:13 kid51 Which -- or what -- is the desired behavior?
00:13 kid51 Would different Parrot users -- i.e., different HLLs -- have a different understanding of "desired"?
00:14 pmichaud kid51: most systems I've used assume stdout to be line buffered, which is what 4.8.0 seems to be doing.
00:14 pmichaud however, from a regressions perspective, since stdout has apparently been unbuffered in parrot for several years... I dunno.
00:15 kid51 Do we know which commit introduced the buffering?
00:16 pmichaud I suspect it was the io branch merge
00:16 pmichaud io_rewrite
00:22 pmichaud the fix in 1fe3b78 doesn't seem very standard, though.  It appears to flush stdout on *any* call to readline, not just those for the standard input filehandle.
00:23 pmichaud so, the 4.8.0 behavior isn't what I'd expect either.
00:31 benabik joined #parrot
00:38 ttbot Parrot 1fe3b78b MSWin32-x86-multi-thread make error http://tt.taptinder.org/cmdinfo/98506
00:47 whiteknight pmichaud: I'll take your word for it, but there definitely was some code in the old system to set up buffering on stdout
00:48 whiteknight so, the old code lied
00:48 whiteknight Un-buffering stdout can be done trivially if you want
00:57 dalek parrot: 959499b | dukeleto++ | docs/binaries/parrot.pod:
00:57 dalek parrot: [doc] Add copyright line back
00:57 dalek parrot: review: https://github.com/parrot/parrot/commit/959499b80c
00:57 dalek parrot: 2c8d7e2 | dukeleto++ | .travis.yml:
00:57 dalek parrot: [travis] Add our coding standard and manifest tests
00:57 dalek parrot: review: https://github.com/parrot/parrot/commit/2c8d7e24db
01:05 kid51_ joined #parrot
01:08 travis-ci joined #parrot
01:08 travis-ci [travis-ci] parrot/parrot#604 (master - 2c8d7e2 : Jonathan "Duke" Leto): The build was broken.
01:08 travis-ci [travis-ci] Change view : https://github.com/parrot/parrot/c​ompare/1fe3b78b366c...2c8d7e24db86
01:08 travis-ci [travis-ci] Build details : http://travis-ci.org/parrot/parrot/builds/2590709
01:08 travis-ci left #parrot
01:37 perlite_ joined #parrot
02:29 ttbot Parrot 2c8d7e24 MSWin32-x86-multi-thread make error http://tt.taptinder.org/cmdinfo/98550
03:13 l3l1p joined #parrot
03:47 l3l1p joined #parrot
03:49 dalek parrot/rurban/json-utf16-gh845: 988986b | rurban++ | / (41 files):
03:49 dalek parrot/rurban/json-utf16-gh845: Merge branch 'master' into rurban/mime-base64-utf8-gh813+gh814
03:49 dalek parrot/rurban/json-utf16-gh845:
03:49 dalek parrot/rurban/json-utf16-gh845: Fixed conflict in:
03:49 dalek parrot/rurban/json-utf16-gh845: ChangeLog
03:49 dalek parrot/rurban/json-utf16-gh845: review: https://github.com/parrot/parrot/commit/988986b46f
03:49 dalek parrot/rurban/json-utf16-gh845: f50380b | rurban++ | / (5 files):
03:50 dalek parrot/rurban/json-utf16-gh845: [GH #845] Fix data_json \unnnn encoding
03:50 dalek parrot/rurban/json-utf16-gh845:
03:50 dalek parrot/rurban/json-utf16-gh845: \u needs to be encoded as utf16 char, not utf8 because they
03:50 dalek parrot/rurban/json-utf16-gh845: are binary different. E.g. \u00a2 is 0xc2a2 in utf8.
03:50 dalek parrot/rurban/json-utf16-gh845:
03:50 dalek parrot/rurban/json-utf16-gh845: Add utf16_chr vtable method for the Parrot_utf16_encoding.
03:50 dalek parrot/rurban/json-utf16-gh845: Add unicode tests to data_json.
03:50 dalek parrot/rurban/json-utf16-gh845: review: https://github.com/parrot/parrot/commit/f50380b17e
04:00 MikeFair joined #parrot
05:17 contingencyplan joined #parrot
05:51 l3l1p joined #parrot
06:04 pmichaud https://gist.github.com/3798179  # comments welcomed.  I'm going to bed now but will read scrollback in the morning when I awaken.
06:05 pmichaud I also added a related comment to issue #874 about the fix that was committed earlier
06:05 pmichaud afk, sleep
07:27 jlaire joined #parrot
07:33 Psyche^ joined #parrot
08:46 lucian joined #parrot
11:16 preflex joined #parrot
12:20 mtk joined #parrot
13:10 jlaire joined #parrot
13:14 dalek rakudo/nom: 031a497 | jonathan++ | src/core/traits.pm:
13:14 dalek rakudo/nom: Ensure &trait_mod:<is>.onlystar == True.
13:14 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/031a49747d
13:14 dalek rakudo/nom: fdf347b | jonathan++ | src/Perl6/World.pm:
13:14 dalek rakudo/nom: Scatter some native types in Perl6::World.
13:14 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/fdf347ba4b
13:14 dalek rakudo/nom: 14f0230 | jonathan++ | src/ (3 files):
13:14 dalek rakudo/nom: Implement binding with declarators.
13:14 dalek rakudo/nom:
13:14 dalek rakudo/nom: This gets things like 'my (:$a, :$b) := foo()' style things working.
13:14 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/14f02309ca
13:14 dalek rakudo/nom: 6f71e7e | jonathan++ | t/spectest.data:
13:14 dalek rakudo/nom: Run S02-names-vars/signature.t.
13:14 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/6f71e7e8dc
13:14 dalek rakudo/nom: 64a2e83 | jonathan++ | src/ (5 files):
13:14 dalek rakudo/nom: Implement 'is hidden' and 'hides'.
13:14 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/64a2e83598
13:14 dalek rakudo/nom: c2e6b2a | jonathan++ | t/spectest.data:
13:14 dalek rakudo/nom: Run S12-class/interface-consistency.t.
13:14 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/c2e6b2a7cc
13:15 bluescreen joined #parrot
13:21 benabik joined #parrot
13:39 rurban msg whiteknight please read pmichaud's gist and comment about new IO buffering. He is worried about all handles and streams, and a "correct" fix for readline. readline should check even if write_buffer is empty if the out handle is buffered or not. Only STDOUT is handled now. Do we get a non-empty write_buffer on non-STDOUT?
13:39 aloha OK. I'll deliver the message.
13:43 pmichaud rurban: I have another test case coming up.
13:57 rurban msg whiteknight please see also our discussion of STD* buffering on #perl6
13:57 aloha OK. I'll deliver the message.
14:04 benabik joined #parrot
14:04 Khisanth joined #parrot
14:04 dalek rakudo/nom: fea947c | jonathan++ | docs/ChangeLog:
14:04 dalek rakudo/nom: A couple of ChangeLog entries.
14:04 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/fea947c525
14:09 benabik_ joined #parrot
14:11 pmichaud msg whiteknight see also latest updates/comments to ticket #847
14:11 aloha OK. I'll deliver the message.
14:23 brrt joined #parrot
14:26 l3l1p joined #parrot
14:28 brrt blegh, designing an instruction set is hard
14:31 * Coke hopes "profit" is one of the instructions.
14:31 brrt that would be awesome
14:33 PacoAir joined #parrot
14:38 brrt nah, i was hoping to build something in-between m0 and pir
14:38 brrt but thats hard
14:43 Coke is there a working m0? I know we had some in progress earlier.
14:44 brrt depends on what you mean by working
14:47 Coke dunno
14:48 Coke if parrot exposed m0 at this point, would w consider that an internal format? would nqp be able to target it, or would there have to be a PIR level? woudl there be a new pir-like level that wasn't pir instead? lower level?
14:51 pmichaud in many ways, nqp isn't really interested in PIR as it exists today.  I think that creating an m0 that tries to replicate PIR as it exists now would be more of a distraction than a help.
14:51 brrt basically, my complaint about m0, if any, is that it is so low-level it is basically useless
14:53 dalek nqp: 29b1d0c | jonathan++ | src/QRegex/P5Regex/Actions.nqp:
14:53 dalek nqp: Toss qalt_nfas from P5Regex.
14:53 dalek nqp:
14:53 dalek nqp: Alternations are always sequential.
14:53 dalek nqp: review: https://github.com/perl6/nqp/commit/29b1d0c52e
14:53 dalek nqp: 7033a27 | jonathan++ | src/QRegex/P5Regex/ (2 files):
14:53 dalek nqp: Basic positional capture support.
14:53 dalek nqp:
14:53 dalek nqp: Seems to get the numbering done the p5 way, at least for basic cases.
14:53 dalek nqp: review: https://github.com/perl6/nqp/commit/7033a27fbb
14:53 dalek nqp: 6c47c7b | jonathan++ | t/p5regex/ (2 files):
14:53 dalek nqp: Some basic p5regex capture tests.
14:53 dalek nqp: review: https://github.com/perl6/nqp/commit/6c47c7bb22
14:53 brrt i.e., if different compilers all compiled down to m0, they could never truly be made to interoperate
14:53 Coke does m0 proscribe calling conventions?
14:54 brrt not if i recall correctly
14:54 Coke if we had something that hid the calling conventions, would that be enough?
14:54 brrt not really
14:54 tadzik m0 wasn't supposed to be something to target, iirc
14:54 brrt you need 'data conventions' too, but that is more tricky than it sounds
14:54 tadzik just something easily jitable, due to low number of opcodes
14:55 tadzik and then there's m1 which compiles to m0, or something
14:55 brrt tadzik: in which case, you need a higher-level representation that may not be easily jittable
14:55 brrt but which is easy to compile hll into, and more interestingly, easy to optimise
14:56 brrt because if javascript can be made to run quickly, any language can
14:56 benabik joined #parrot
14:56 tadzik brrt: that's what m1 is about
14:56 tadzik (was?)
14:59 brrt m1 would then have to be a reasonable target for compilation
15:00 benabik_ joined #parrot
15:01 tadzik that was my understanding, yes
15:01 brrt my understanding was that m1 would be some c-alike
15:02 brrt as in, for humans
15:02 tadzik that's how it looks
15:02 tadzik hm
15:02 Coke ... didn't someone already do that also?
15:02 tadzik so maybe someone wanted a compiler toolkit generating m0
15:02 tadzik or something
15:02 * tadzik shrugs
15:02 tadzik I don't believe this will happen actually :(
15:03 brrt shame
15:08 brrt anyway, that was why i wanted to implement a set that was high-level enough to enforce calling and data conventions
15:08 brrt which is hard
15:10 * brrt was sure he could find the design document of m0
15:12 brrt https://github.com/parrot/parrot/bl​ob/m0/docs/pdds/draft/pdd32_m0.pod
15:12 brrt here it is
15:16 dmalcolm joined #parrot
15:17 l3l1p joined #parrot
15:20 rurban For me m0 is just a simple LLVM rewrite, without all the infrastructure and optimizations of LLVM. Why bother
15:22 rurban If we want to create jit-near microcode and jit it with llvm, we need to create llvm .bc not m0 bytecode.
15:23 Coke is llvm supported on all platforms we currently target?
15:23 rurban I have no idea
15:23 rurban it runs on most processors, but not on vms
15:24 rurban mips also not
15:24 brrt i definetly see the value in something  low-level to pir
15:25 rurban oh, mips is supported. and ia64 also, so vms would run
15:25 dalek parrot: c2c9597 | dukeleto++ | MANIFEST:
15:25 dalek parrot: [t] Update manifest to make manifest tests happy
15:25 dalek parrot: review: https://github.com/parrot/parrot/commit/c2c95972e0
15:27 rurban uh, utf16->to_encoding(asciistring) => ucs2 ?
15:29 rurban Oh, I see. optimization
15:45 Coke rurban: which parts of parrot coudl be swapped out for llvm tools/code?
15:46 rurban Parts of the runtime
15:47 rurban But I'm mostly seeing potential for a better nqp backend based on vmkit, than parrot.
15:47 rurban It's the calling convention and string handling which is awful. and almost not fixable
15:52 ttbot Parrot c2c95972 MSWin32-x86-multi-thread make error http://tt.taptinder.org/cmdinfo/98615
16:12 preflex_ joined #parrot
17:06 NotFound joined #parrot
17:07 preflex_ joined #parrot
17:10 brrt joined #parrot
18:13 tuxit joined #parrot
18:20 contingencyplan joined #parrot
18:20 schmooster joined #parrot
18:31 benabik joined #parrot
19:18 davidfetter joined #parrot
19:23 brrt joined #parrot
19:24 dalek rakudo/nom: 2d0e2de | pmichaud++ | t/spectest.data:
19:24 dalek rakudo/nom: Remove extra copy of integration/rule-in-class-Str.t added by 19d7cd2b9a.
19:24 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/2d0e2dec93
19:40 preflex joined #parrot
19:58 zby_home joined #parrot
19:59 bluescreen joined #parrot
20:15 benabik joined #parrot
20:49 dalek parrot/rurban/bitwise_uni-gh848: f88d598 | rurban++ | src/pmc/string.pmc:
20:49 dalek parrot/rurban/bitwise_uni-gh848: [cage] Typo in the string.pmc trans method pod
20:49 dalek parrot/rurban/bitwise_uni-gh848: review: https://github.com/parrot/parrot/commit/f88d59805d
20:49 dalek parrot/rurban/bitwise_uni-gh848: 04f1986 | rurban++ | src/string/encoding/utf16.c:
20:49 dalek parrot/rurban/bitwise_uni-gh848: Micro-optimize utf16_chr by checking 0 beforehand
20:49 dalek parrot/rurban/bitwise_uni-gh848: review: https://github.com/parrot/parrot/commit/04f198609a
20:49 dalek parrot/rurban/bitwise_uni-gh848: 6c41a21 | rurban++ | / (4 files):
20:49 dalek parrot/rurban/bitwise_uni-gh848: [GH #848] Support unicode strings for bitwise ops
20:50 dalek parrot/rurban/bitwise_uni-gh848:
20:50 dalek parrot/rurban/bitwise_uni-gh848: bands, bors, bxors and bnots understand now more multi-byte strings.
20:50 dalek parrot/rurban/bitwise_uni-gh848:
20:50 dalek parrot/rurban/bitwise_uni-gh848: Old docs:
20:50 dalek parrot/rurban/bitwise_uni-gh848: Performs a bitwise C<OR> on two Parrot strings, performing type and encoding
20:50 dalek parrot/rurban/bitwise_uni-gh848: conversions if necessary.  Returns the result as a new string.
20:50 dalek parrot/rurban/bitwise_uni-gh848:
20:50 dalek parrot/rurban/bitwise_uni-gh848: Added now:
20:50 dalek parrot/rurban/bitwise_uni-gh848: Same encodings are compared bitwise.  Different two-byte encodings are first
20:50 dalek parrot/rurban/bitwise_uni-gh848: converted down to latin1, and if that fails upgraded to ucs2 and if that
20:50 dalek parrot/rurban/bitwise_uni-gh848: fails to ucs4.
20:50 dalek parrot/rurban/bitwise_uni-gh848: 2 byte <=> 4 byte conversion is not supported, thus e.g. utf8->utf16 fails.
20:50 dalek parrot/rurban/bitwise_uni-gh848: But 2 byte to 1 byte is attempted.
20:50 dalek parrot/rurban/bitwise_uni-gh848: review: https://github.com/parrot/parrot/commit/6c41a2111d
20:50 dalek parrot/rurban/json-utf16-gh845: 1313cd4 | rurban++ | compilers/data_json/data_json/pge2pir.tg:
20:50 dalek parrot/rurban/json-utf16-gh845: GH #845 use ucs2 not utf16 for json \u values
20:50 dalek parrot/rurban/json-utf16-gh845:
20:50 dalek parrot/rurban/json-utf16-gh845: This is safer.
20:50 dalek parrot/rurban/json-utf16-gh845: review: https://github.com/parrot/parrot/commit/1313cd42e1
20:50 dalek parrot/rurban/json-utf16-gh845: 274df5d | rurban++ | src/string/encoding/ucs2.c:
20:50 dalek parrot/rurban/json-utf16-gh845: GH #845 Add ucs2_chr for data_json
20:50 dalek parrot/rurban/json-utf16-gh845: review: https://github.com/parrot/parrot/commit/274df5d890
20:53 dalek nqp: f12484a | pmichaud++ | / (2 files):
20:53 dalek nqp: Back PARROT_REVISION down to 4.4.0, bump VERSION to 2012.09.1
20:53 dalek nqp: review: https://github.com/perl6/nqp/commit/f12484a8f9
20:55 rurban I'm off now for a few hours.
21:10 dalek rakudo/nom: acf8f17 | pmichaud++ | / (3 files):
21:10 dalek rakudo/nom: Bump NQP revision to 2012.09.1, restore IO::Socket::INET to use older Parrot interface, disable IO::Socket::INET tests in spectest.
21:10 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/acf8f17054
21:10 dalek rakudo/nom: 5c5b15b | pmichaud++ | / (2 files):
21:10 dalek rakudo/nom: Revert a bit more of 71fc9c to get sockets to work as they did in 2012.08.
21:10 dalek rakudo/nom: This also causes S32-io/IO-Socket-INET.t to start passing again.
21:10 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/5c5b15bf0e
21:10 dalek rakudo/nom: 81cd16f | pmichaud++ | docs/ChangeLog:
21:10 dalek rakudo/nom: Update ChangeLog for 2012.09.1.
21:10 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/81cd16f0bf
21:21 dalek rakudo/nom: cbe6eea | pmichaud++ | docs/announce/2012.09.1:
21:21 dalek rakudo/nom: Add announcement for 2012.09.1 .
21:21 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/cbe6eeaebc
21:22 dalek rakudo/nom: 5f876d7 | pmichaud++ | docs/release_guide.pod:
21:22 dalek rakudo/nom: Update release_guide.pod with 2012.09.1 release.
21:22 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/5f876d79aa
21:28 dalek rakudo/nom: 7d227de | pmichaud++ | VERSION:
21:28 dalek rakudo/nom: [release] bump VERSION
21:28 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/7d227de7cc
22:52 whiteknight joined #parrot
22:54 whiteknight good evening, #parrot
23:00 bluescreen_ joined #parrot
23:09 whiteknight I cannot, for the life of me, figure out how the previous IO system was accomplishing this buffering behavior
23:14 l3l1p joined #parrot
23:26 whiteknight actually, I think I know what it's doing: it doesn't look like stdout is being buffered at all in the old system
23:26 whiteknight ...which makes some sense if I'm reading this right
23:28 whiteknight pmichaud: ping
23:28 dalek parrot: 3260e22 | Whiteknight++ | src/io/api.c:
23:28 dalek parrot: Undo a prospective fix from rurban++. We don't want to flush stdout every time we read from any filehandle.
23:28 dalek parrot: review: https://github.com/parrot/parrot/commit/3260e22002
23:28 dalek parrot: 2922c18 | Whiteknight++ | src/io/api.c:
23:28 dalek parrot: On second read through, it doesn't appear that the old IO system had a write buffer on stdout. Take that away in the new system to try and fix some rakudo issues reported by pmichaud++
23:28 dalek parrot: review: https://github.com/parrot/parrot/commit/2922c18814
23:34 pmichaud whiteknight: pong
23:35 whiteknight pmichaud: those last two commits might fix your stdout buffering issues
23:35 whiteknight I ran a test locally, when you get a chance can you confirm it with Rakudo?
23:35 pmichaud well, it could be tested with the pir code in the issue, too :)
23:36 whiteknight yes, that's what I did. If that's enough testing, then we can call the ticket complete
23:37 pmichaud yes.  however, we have another problem with standard input that needs resolving too.
23:37 pmichaud so far I haven't been able to duplicate it on any of my systems, but it's been reported by Coke, jnthn, and TimToady so I'm fairly confident the bug exists
23:38 pmichaud oh, and moritz  :)
23:38 pmichaud I'll try master now
23:39 whiteknight okay, those are all trustworthy sources
23:39 whiteknight what's the bug?
23:39 pmichaud when reading lines of input, none of them are delivered to the program until EOF is sent
23:39 whiteknight hmm, that would seem to be a definite bug
23:40 travis-ci joined #parrot
23:40 travis-ci [travis-ci] parrot/parrot#606 (master - 2922c18 : Whiteknight): The build was fixed.
23:40 travis-ci [travis-ci] Change view : https://github.com/parrot/parrot/c​ompare/c2c95972e063...2922c188143b
23:40 travis-ci [travis-ci] Build details : http://travis-ci.org/parrot/parrot/builds/2602966
23:40 travis-ci left #parrot
23:46 benabik joined #parrot
23:48 pmichaud whiteknight: 2922c18 seems to leave the standard output unbuffered again.
23:48 pmichaud (i.e., yes, it's the behavior before 4.8.0, but not necessarily the behavior we'll want)
23:50 whiteknight yeah, I'm just trying to get back to the same baseline. io_cleanup1 did not intend to make many breaking changes
23:50 whiteknight but yes, we want to do the right thing going forward
23:51 whiteknight apparently I have some backlogging to do about expected behaviors
23:52 dalek Heuristic branch merge: pushed 45 commits to parrot/rurban/mime-base64-utf8-gh813+gh814 by rurban

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

Parrot | source cross referenced