Parrot 3.5.0 "Menelaus" released | parrot.org | Log: irclog.perlgeek.de/parrot/today | #parrotsketch meeting Tuesday 1930 UTC
Set by moderator on 12 July 2011.
bubaflub jay: you can always just be a polyglot 00:00
jay can I write inline wixed like I did with the Q:PIR? 00:01
<winxed>
bubaflub jay: no, the entire file would have to be Winxed
jay ok
bubaflub jay: if you are changing some existing NQP, it might be best just to stick wtih it
*with
jay Argh. Have to go for now, back later. Are there docs for Winxed? I'm having trouble even finding how to create the FixedFloatArray from NQP. I hate to ask every little thing. Are there good NQP docs or should I start looking at the source? 00:04
whiteknight whiteknight.github.com/Rosella/win...index.html 00:05
it's not complete, but better than nothing
00:09 lucian left
Felipe hm? I haven't permission to create ticket at Trac 00:12
00:12 bluescreen left
Felipe aren't bugs intended to be filed in the Trac instead of the old rt one? 00:14
cotto_work Felipe: just a sec
whiteknight yeah, but we were having bad spam problems
Felipe k
ah :(
whiteknight cotto_work: we should open that up again
cotto_work Felipe: now you do
whiteknight: we can try.
00:15 lichtkind_ joined
bubaflub whiteknight: got a moment for an NCI question? 00:15
whiteknight cotto_work: I think I just added TICKET_CREATE and TICKET_MODIFY permissions for all users 00:16
let's try that, see how it works
bubaflub: NO MOMENTS!
bubaflub: actually, I have all the time in the world. What do you need?
bubaflub whiteknight: ENOMOMENTS
cotto_work whiteknight: go for it. If we get more than a couple trac spam messages per day, we can lock it down again.
00:17 lichtkind left
bubaflub whiteknight: i'm working on my NCI thunks and i need to generate some specific for my projects - are the only thunks included with Parrot located in src/nci/core_thunks.nci and src/nci/extra_thunks.nci ? 00:17
whiteknight yeah, those are the two files that are used in parrot 00:18
bubaflub whiteknight: great. i plan on writing a script that'll read my project's NCI definition file, and then those two, and then spit out a definition file of any thunks that my project needs but aren't included in parrot
dukeleto's project and jay's project could probably use it
whiteknight bubaflub: that sounds awesome 00:19
bubaflub: I think there is a way to get a list of available thunks from parrot
bubaflub seen plobsing 00:20
aloha plobsing was last seen in #parrot 1 hours 49 mins ago joining the channel.
bubaflub nuts, must have just missed him
whiteknight there is an IGLOBALS_NCI_FUNCS object 00:21
.include 'iglobals.pasm'
$P0 = getinterp
$P1 = $P0["globals"]
$P2 = $P1[.IGLOBALS_NCI_FUNCS]
I *think* that should contain what you want 00:22
00:22 woosley joined 00:23 lichtkind_ left
whiteknight hmmm...maybe not 00:24
bubaflub whiteknight: nah. i'm seeing there is HAS_EXTRA_NCI_THUNKS 00:25
also, i'm seeing our config hash has alot of both lowercase and uppercase versions of the same information
dukeleto bubaflub: that script sounds useful. 00:26
00:27 lichtkind joined 00:28 woosley left
bubaflub dukeleto: i should have something by the end of tonight 00:28
dukeleto i sure am good at making irc clients duel each other 00:29
whiteknight heh. I just found a 1-line segfault 00:32
awesome
2-line
winxed: function main[main]() { typeof(getinterp()[4]); }
00:34 particle left
cotto_work They're getting rarer. 00:34
bubaflub whiteknight: i'm not segfaulting on that Winxed (nor on the generated PIR);
whiteknight bubaflub: do you have libffi installeD?
bubaflub whiteknight: yep
whiteknight I suspect that value is NULL in some situations, not PMCNULL
I'm putting a patch together now
bubaflub i printed out the value, i'm getting an UnManagedStruct 00:35
cotto_work whiteknight: why does that segfault for you?
whiteknight I don't know. I'm looking into it 00:36
it's definitely segfaulting though. I'm doing a gitpull 00:38
00:40 theory left 00:41 particle joined
dalek rrot: 929a061 | Whiteknight++ | src/pmc/parrotinterpreter.pmc:
Fix rare segfault situations where there is a NULL in the iGlobals array, instead of a PMCNULL
00:43
00:44 rurban_ joined
dalek TT #2151 created by Felipe++: Memory leak on imcc_compile_buffer_safe() function 00:46
TT #2151: trac.parrot.org/parrot/ticket/2151
00:46 rurban left 00:47 rurban_ is now known as rurban
bubaflub Felipe++ - nice patch on the ticket 00:48
whiteknight Felipe++ indeed. I wrote that function, so now I'm embarrassed 00:49
msg kid51: I think I updated trac to allow all users to create tickets again. If we see lots of spam again, we can shut that off. It's an experiment 00:58
aloha OK. I'll deliver the message.
whiteknight I'm going to bed now. Talk to you guys later 00:59
01:00 whiteknight left
dalek rrot-gmp: d039693 | bubaflub++ | / (2 files):
NCI thunk stuff:

bin/ncithunker.pl script to generate src/GMP/thunks.nci the script reads Parrot's available thunks and my NCI definition and then outputs which thunks I need in the proper format
01:02
Felipe :) 01:05
bubaflub Felipe: if you are familiar with Github, you can also send pull requests 01:06
Felipe okay, thanks 01:08
01:11 lichtkind left
Felipe The regenerated imclexer.c must be committed too 01:12
cotto_work Felipe: Yes. Run Configure.pl with --maintainer to get the right magic set up so that those files get re-generated. 01:15
Felipe ah cool 01:16
01:16 daniel-s joined 01:18 rurban left
cotto_work whiteknight++ for the fix 01:20
01:20 wagle left 01:21 wagle joined
bubaflub cotto_work: could you help me with this C error? gist.github.com/1081697 01:26
01:26 daniel-s left
bubaflub also, dukeleto: check out my strange C error trying to compile an NCI thunk: gist.github.com/1081697 01:31
cotto_work bubaflub: I have to take off in a few minutes, unfortunately. I'll look at it later this evening if needed. Where does the project live, and is the code to reproduce that pushed? 01:35
bubaflub cotto_work: github.com/bubaflub/parrot-gmp, it's not pushed yet. i can push it to a branch 01:36
jay Fixed vs Resizable issue... "init_pmc() not implemented in class 'FixedFloatArray'? Easy example, gist.github.com/1081713 01:40
01:40 particle1 joined
cotto_work bubaflub: I'm out. Shoot my non-work counterpart a msg if nobody's around to help. 01:42
01:44 particle left
dalek R: 1799696 | (Jay Emerson)++ | / (2 files):
Added HELP file for my current "gotchas".
01:51
01:51 kid51 joined
kid51 backscrolls 01:53
Felipe ping 01:54
Felipe kid51: pong 01:55
01:55 fahad left
kid51 Did you get your Trac ticket posted? 01:55
Felipe yes
kid51 And you spell your login with upper-case F, correct?
Felipe exact. 01:56
01:56 fahad joined
kid51 okay. On our permissions page, your name was entered as 'felipe'. I'm going to change it to 'Felipe' now so that it's consistent with the Users page. 01:57
So, you're now in the 'developer' user group as 'Felipe', which enables you to open and comment on tickets, comment on wiki pages, etc. 01:58
Felipe thanks!
kid51 My hunch is that the permissions page is not case-sensitive, hence, once someone (whiteknight?) made 'felipe' into a developer, you were able to open that Trac ticket. 01:59
But it's best to be consistent.
02:03 contingencyplan left
Coke TLDR. 02:26
02:37 fahad left 02:43 fahad joined
dalek TT #2152 created by jkeenan++: t/pmc/string.t, t/library/streams.t: new test failures 02:51
TT #2152: trac.parrot.org/parrot/ticket/2152
02:51 kid51 left
bubaflub msg cotto: updated gist - the C file that i'm trying to compile and error is in this gist: gist.github.com/1081697 03:00
aloha OK. I'll deliver the message.
dalek TT #2153 created by Felipe++: Memory leak in compile_file functions 03:07
TT #2153: trac.parrot.org/parrot/ticket/2153
jay ping bubaflub 03:12
bubaflub pong jay 03:13
jay So I figured something out (or re-invented it.... maybe Whiteknight hinted at it):
This works (NQP calling PIR):
my $vec := Q:PIR { %r = new ["FixedFloatArray"], 2 };
This works: 03:14
my $vec := pir::new("ResizableFloatArray");
This does not work:
my $vec := pir::new("FixedFloatArray", 2);
Go figure.
benabik ~~
dukeleto: I did my midterm! 03:15
bubaflub jay: heh. that's news to me
jay: a lot of the perl6 people know a lot more about NQP than i do 03:16
jay So if I wanted to give Winxed a fair look, should I start with your code? Is it mature enough to have docs?
(by "it" I meant winxed, not your code)
bubaflub jay: whiteknight has some good docs for Winxed 03:18
jay: also NotFound wrote winxed, and he's usually around to answer a few questions
jay In spite of the name, huh?
bubaflub jay: yep 03:19
jay: and yes, my code is Winxed. the only piece of NQP i have is t/harness 03:20
jay Ok. Maybe I'll spend some time on it tomorrow. NQP has been a little frustrating. I would guess there might be discussion of ditching it and replace it with Winxed...
bubaflub jay: ok. there is the possibility to have different languages in different files 03:23
jay: maybe the compiler part uses NQP, some of the bindings can use Winxed, and so on
benabik msg dukeleto I completed the midterm evaluation today. Before you reminded me, even!
aloha OK. I'll deliver the message.
jay Yes, understood. I think I can manage that. I was just thinking "bigger picture." Can't code all the time... !-)
bubaflub jay: makes sense. 03:25
Felipe++ - thanks for all the valgrind reports; that work must be tedious 03:26
dalek R: a64f6a8 | (Jay Emerson)++ | src/nqr/Runtime.pm:
Q:PIR and pir:: obviously not the same
03:31
benabik I'm getting an odd message when building Rakudo on my branch. "Lossy conversion to single byte encoding" Anyone know what that could be? 03:33
dalek R: aa9c615 | (Jay Emerson)++ | HELP:
Keep HELP up to date
bubaflub jay: what's the ultimate goal for NQR? something close to R syntax?
jay It's not really a grammar issue, that is entirely do-able. We'd like to create a basic, scalable version of R, leveraging past work that really identified some of the core design limitations of R. Parrot seems like a promising platform, so this is "proof of concept" I suppose. 03:35
On the memory side of things, allow memory-mapped files for large data objects. We've also messed about with shared memory and other stuff.
bubaflub jay: alright, that makes sense. 03:36
jay 64-bit indexing: freebie. R falls flat, there, and it would require going through 20-30 years of code to save that codebase.
R is pretty sweet though, for most things. But it can't scale indefinitely, and statistics problems are only getting larger.
R has barely added some bytecode support... you guys are huge there. 03:37
bubaflub jay: i've heard and read about R, but never had to use it; i've done Matlab/Octave type stuff though
jay R is not threadsafe. Period end of story.
bubaflub jay: yeah, there are a lot of things you could get for free. especially if more languages are on top of Parrot
jay: in theory you could get free access to Python3 or JavaScript or Perl6
jay Similar to Matlab/Octave in many ways. Yes, that is attractive. 03:38
Graphics will be interesting to explore...
bubaflub jay: i forgot who did a lot of the OpenGL work, but the bindings are there. might need some updating, though
jay Matlab/Octave don't really have the extensive statistics libraries that R does... so a "home run" would need to support R extension packages. But I figure that sort of full compatibility is close to impossible unless a lot of people jump on the bandwagon. 03:39
bubaflub jay: yeah, more just general Linear Algebra stuff is what i've worked with. how are R extensions written? 03:40
jay In R, some with C/C++. We think we can handle the R/C/C++ interface in Parrot, though -- we're doing a far bit of thinking, not just coding in the dark as it probably seems... 03:41
< fair bit > 03:42
bubaflub jay: cool. how do the GSL bindings fit into all of this?
jay By using them I'm not directly using the R Project stuff (even though I could, perhaps, for some things). That is an abstract plus at the moment for political reasons. 03:43
I know the R Project had some rather complicated license issues with some stuff that is well-buried under the hood, and I'd rather avoid any of that.
bubaflub jay: ok, that makes sense. 03:44
jay I think worrying about much of this is WAY premature at the moment. But I can start to see how things could come together quickly. 03:45
03:45 jsut_ joined
jay Well, that's all for me tonight. Thanks again for the help, bubaflub++ 03:46
bubaflub jay: talk to you tomorrow
jay Tomorrow: GMP with Winxed, and maybe some class stuff. 03:47
03:50 jsut left 04:01 woosley joined
cotto ~ 04:09
~~
Hmmm. No msg.
benabik msg cotto Have a msg. 04:10
aloha OK. I'll deliver the message.
cotto ohai 04:14
worked that time
soh_cah_toa whenever somebody says "ohai" i always immediately think "can has stdio?" 04:17
:)
cotto That's a proper instinct. 04:18
bubaflub goodnight, #parrot 04:21
cotto 'night bubaflub 04:22
04:25 particle1 left 04:37 daniel-s joined
dalek p: abdf378 | pmichaud++ | src/ (2 files):
Refactor building of match object.
04:37
p: 985fd7d | pmichaud++ | src/QRegex/Cursor.nqp:
Cache a match object once we've built it.
kudo/nom: 5aecd55 | pmichaud++ | / (10 files):
Merge branch 'nom' of github.com:rakudo/rakudo into nom
04:45
kudo/nom: d5a8c7e | pmichaud++ | / (4 files):
Update Match, Cursor, and Capture objects. Indexed access to
cotto Fun with C: blog.regehr.org/archives/558 05:57
06:02 particle joined 06:05 awwaiid left, awwaiid joined 06:23 soh_cah_toa left 06:36 fperrad joined 06:38 contingencyplan joined 06:55 Eclesia joined 07:08 preflex left 07:11 mj41 joined, preflex joined 07:17 writtencode left
dalek rrot/m0-spec: f359fc4 | cotto++ | docs/pdds/draft/pdd32_m0.pod:
add a couple experimental byte manipulation ops
07:40
rrot/m0-prototype: b5ae2ab | cotto++ | src/m0/perl5/m0_ (2 files):
implement the [gs]et_byte ops, though no tests yet
07:41
cotto msg dukeleto I'd like to know your thoughts on the set_byte and get_byte ops I added to M0. After talking with chromatic and thinking, this seems like it might be workable. 07:42
aloha OK. I'll deliver the message.
cotto msg dukeleto I want M0 primitive strings to be prefixed by a header with the size and encoding (2 words total). Thoughts on how that'd fit together would be appreciated. 07:44
aloha OK. I'll deliver the message.
cotto sleeps
08:29 fperrad_ joined 08:33 fperrad left, fperrad_ is now known as fperrad 08:34 Drossel joined 08:37 Kulag left 08:52 dodathome joined, Drossel left, Kulag joined
dalek kudo/nom: 88f4119 | moritz++ | src/Perl6/Actions.pm:
fix $0, $1 etc.
08:57
09:04 Drossel joined, Kulag left 09:19 contingencyplan left
dalek kudo/nom: 45c0697 | moritz++ | t/spectest.data:
6 more passing test files
09:27
09:55 preflex left 09:57 preflex joined 10:09 woosley left 10:21 lucian joined 10:24 JimmyZ joined
Felipe good morning 10:33
10:38 preflex left 10:40 preflex joined 10:41 Eclesia left 10:46 JimmyZ left 10:49 ambs joined
dalek kudo/nom: 064bcc4 | jonathan++ | src/Perl6/ (2 files):
Flesh out actions a bit for enumerations. Very much a first cut - only handles a few simple cases.
11:01
kudo/nom: fed99c4 | jonathan++ | src/Perl6/Metamodel/BaseType.pm:
Need .^parents in BaseType role.
kudo/nom: 74c67f8 | jonathan++ | src/core/Enumeration.pm:
Sketch out a few bits in the Enumeration role.
kudo/nom: 9c760e1 | jonathan++ | src/Perl6/Metamodel/EnumHOW.pm:
Create enumeration values at enum compose times, and include the key.
11:02 Themeruta joined, Themeruta is now known as NotFound_b
NotFound_b cotto: ping 11:02
msg cotto Looks like there is a mistake in github.com/parrot/parrot/commit/2b...ceafde8c87 - It changed t/library/perlhist.txt 11:05
aloha OK. I'll deliver the message.
11:05 NotFound_b left
dalek kudo/nom: ef31cef | tadzik++ | src/core/operators.pm:
Make n/1 Rats be Ints in sequence generation
11:17
11:45 ambs left 11:46 kid51 joined 11:56 ambs joined 12:15 JimmyZ joined 12:18 bluescreen joined
dalek kudo/nom-num: f7e4cec | moritz++ | src/Perl6/Actions.pm:
(re-)introduce radcalc, but smarter than before
12:27
kudo/nom-num: 64fe676 | moritz++ | src/Perl6/Actions.pm:
allow arbirary number of trailing zeros. Wins back the few tests that the previous commit regressed
kudo/nom-num: 8097419 | moritz++ | src/Perl6/Actions.pm:
hopefully speed up stripping of trailing zeros
kudo/nom-num: 09a43b7 | moritz++ | src/Perl6/Actions.pm:
remove (mostly PIR) functions that are now mostly unused
12:28
kudo/nom-num: e939a8b | moritz++ | src/Perl6/Actions.pm:
get :16<DEAD_BEEF> style literals working
12:29 kid51 left 12:35 whiteknight joined
jay Good morning, whiteknight. 12:35
How are things with your new mouse? 12:36
bubaflub ~ 12:43
whiteknight good morning jay
jay and also you, bubaflub 12:44
whiteknight jay: They're better than I could have possibly imagined. Compared to the pain I was living with, the new mouse is like heaven with a little laser on the bottom
bubaflub whiteknight: who could ask for more
morning jay
whiteknight I can move my cursor to where I want it moved, I don't have to worry that a simple touch of the mouse is going to trigger a million weird gesture shortcuts, it's wonderful
Felipe morning guys
whiteknight good morning Felipe
12:45 smash joined
smash hello everyone 12:45
Felipe hello
jay bubaflub... Integer.winxed defines class Integer within namespace GMP? The var ptr; is probably what the underlying pmc object gets, just a pointer to this structure. You define all the attributes (functions), because it isn't a subclass inheriting anything. The "using" gives you access to one of those functions previously dynloaded in raw.pir and available in GMP.Raw? 12:52
bubaflub jay: 1) yes, i put a class Integer into the GMP namespace so you can have a GMP::Integer
jay: 2) yes, the var ptr just holds a pointer to the struct. 12:53
jay: 3) the using statement i'm not 100% clear about, but it pulls in functions from raw.pir (which is put into a namespace GMP::Raw)
jay Ok. I could see getting to like Winxed. Having explicit types seems safer than what Perl* lets us get away with. 12:54
bubaflub jay: the types in Winxed are a wrapper around Parrot types, but you can see how in my Winxed GMP::Integer functions I can do some basic type checking - make sure that var is actually a GMP::Integer. 12:55
jay bubaflub's indentation is impeccable, he has helpful incode comments, and he's impressively organized. Any confusion is my fault. I recommend giving him an "A" on his midterm exam. Er... you did have one, didn't you? 12:56
bubaflub jay: haha, yes i did have a midterm for GSoC. 12:57
moritz jay: the midterm evaluations are mostly just pass/fail
bubaflub jay: that code is generated, which helps with the indentation.
jay < sshhh > I know that, but you don't have to tell everyone.
moritz ok :-) 12:58
jay Code generating code... < wistful sigh > takes me back about a decade when I did a short 3-year stint as a systems administrator. Mostly Linux and Solaris, with some Microsoft suffering on the side. 12:59
dalek rrot: 8c150e2 | bubaflub++ | t/library/perlhist.txt:
fix test file that got clobbered in 2b98378, NotFound++

this fixes t/library/streams.t and t/examples/library.t
bubaflub msg kid51 8c150e2 fixes the two new errors you noticed 13:01
aloha OK. I'll deliver the message.
13:04 NotFound_b joined
NotFound_b bubaflub: using namespace makes anything in the target namespace available from the current scope: functions, classes and constants. 13:07
bubaflub NotFound_b: ah, so i could just do "using namespace GMP.Raw;" instead of lots of little "using GMP.Raw.blahblah;"? 13:10
whiteknight NotFound_b: How does that work, it does a runtime search? 13:11
And if I do "using Foo; using Bar", and I call "baz()", how does it know where to find the function? 13:12
13:12 autark left
NotFound_b No, using namespace is strictly compile time. The namespace declaring that things must be in the current compilation unit. 13:12
13:12 autark joined
whiteknight oh, okay. So we still need a forward declaration? 13:12
NotFound_b But now that we have $include is less of a problem.
whiteknight $include works with whole winxed files?
jay bubaflub: could there be a single "using namespace GMP.Raw" without having a "using" inside every one of the functions? 13:13
whiteknight It looks like I have a lot of catching up to do
jay Or is that what this $include would do? Haven't seen that yet.
NotFound_b whiteknight: yes, I've been lazy and don't use a specialized parser for includes. But you should put on them only const and extern declarations to be safe. 13:14
13:14 GodFather joined
NotFound_b jay: no one uses it yet, being added this week. 13:15
bubaflub NotFound_b: so you're saying my two options are 1) $include my file and then using namespace GMP.Raw; or 2) just using it regularly (load_bytecode) and have a bunch of using GMP.Raw.blah; statements
jay lol ok, I'll sit tight until you guys tell me to jump. I'll copy bubaflub for now.
NotFound_b bubaflub: no, the idea is that you can create an include file for your module with extrnal declarations for the things it provides. 13:17
whiteknight like a .h file 13:19
I think I'm going to be providing something like that for Rosella soon 13:20
NotFound_b I'm going to commit to WinxedGtk soon, as example of use. 13:21
13:21 NotFound_b left 13:22 NotFound_b joined
NotFound_b Also, you can put a $load for the library in the include file, but I'm not sure if that is going to be a supported practice. 13:22
whiteknight what do you mean, not supported? 13:24
I was thinking that sounded like a perfect solution
NotFound_b Allowing it if some day a restricted parser for includes is added. 13:25
whiteknight why do you think it would be restricted?
13:25 Eclesia joined
Eclesia hi 13:25
NotFound_b whiteknight: if people start using it, users of the libraries lost tha ability to decide at what point the bytecode is loaded. 13:26
whiteknight Okay, that makes sense
NotFound_b Without it, users can put its own $load, or use load_bytecode where appropiate. 13:28
rblackwe Quick ad for PPW. We seem to be lacking parrot/rakudo/... talks anyone interested in helping fix that? ... pghpw.org/ppw2011/newtalk 13:31
whiteknight Rosella is going to use that feature internally, to automatically include prerequisite libraries
13:33 Coke left
NotFound_b Internal usage is fine. 13:33
13:34 Coke joined
Eclesia If my project can serve as an exemple (on dependency management) : I intend to pack *pbc files in a zip. each zip is what I call a 'module' which at end can be loaded or unloaded on the fly. Eria will only work with modules, a single file won't work alone. each module we have somekind of metadata associated saying 'I need this module or another' and the module system takes care to call all the load_libraries necessary. 13:34
NotFound_b Eclesia: interesting, but winxed is a lower level beast, must be close to the parrot core level. 13:38
Eclesia NotFound_b: I was just an example :) . so that you don't remove the load_lib code 13:39
I'm also wondering, is there a function to unload ?
NotFound_b Eclesia: no. Some day the garbage collector will remove the modules no more in use. 13:40
Currently implementation details don't allow that. 13:41
whiteknight msg dukeleto I sent out reminder emails to GSOC mentors and students who haven't filled out reviews yet. Deadline is tomorrow so I am planning to pester
aloha OK. I'll deliver the message.
Eclesia NotFound_b: what will happen If I load a class. then load another class with the same name and same namespace (a differnt version for example) ? 13:42
NotFound_b Eclesia: nothing good
Eclesia parrot does not have a concept of 'classloader' ? 13:43
to avoid such conflicts ?
13:43 Coke left 13:44 Coke joined
moritz a class loader wouldn't be enough 13:44
Felipe whiteknight: have you seen my pull request?
moritz parrot has a global registry for namespaces
NotFound_b Eclesia: there is a close bind between classes and its associated namespaces right now. That may change in the future when object model is changed to 6model or something like that.
moritz allowing everybody to read and write there means you can't import different versions of the same class (if that write to the namespaces) 13:45
... unless the author of that class took care of uniqueifying the namespace name based on the version, or something
or shoving it into a different HLL or so 13:46
Eclesia hm.. so I could add version number a on moment in the namespace
moritz but since parrot allows the loaded modules so much freedom, it also can't guarantuee much
if you are the author of the modules, yes 13:47
NotFound_b WinxedGtk using $include: github.com/NotFound/WinxedGtk/comm...9659e2cef4
jay Winxed question: var foo = [1.1,2.2]; Now, I want to pass the pointer to the data to a C function, like gsl_stats_mean(foo, 1, 2). May not be quite right... hints? I get an answer, but a junky answer.
NotFound_b jay: this is a PMC array, not a float array.
jay: you can use: float foo[] = [ 1.1, 2.2 ]; 13:48
jay Ok, I'll try that.
Bingo! NotFound_b++ 13:49
dalek kudo/nom-num: 01df600 | moritz++ | src/Perl6/ (2 files):
refactor numeric constants to do the PAST::Want magic in a single place
13:50
NotFound_b jay: you can also use: float foo[2] = [ 1.1, 2.2 ]; if you want a fixed size array. 13:51
jay And would float foo[2]; simply declare an empty fixed size array of length 2? 13:52
NotFound_b jay: yes
whiteknight oh wow, I wasn't aware of that syntax
NotFound++ 13:53
13:53 mtk joined
NotFound_b Well, not empty, just uninitialized. 13:53
whiteknight NotFound: I'm going to need to update all my documentation! 13:54
jay I now have 4 working versions of a dumb little function using something from GSL: Winxed, and 3 versions with various combinations of PIR and NQP. A substantial building block. 13:55
whiteknight that's good, right? Having options is good
jay YES! Good for understanding, too.
NotFound_b Note that foo is not granted to keep its type. That declarations really declare a var, the syntax just generates a runtime initialization.
jay In NQP, why isn't pir:: simply a one-line Q:PIR { }? 13:56
Eclesia GSL is in parrot ? 13:57
or did you made bindings ?
moritz jay: because that way it's easier to get arguments
whiteknight jay: nicer syntax, coercion of data types, automatic allocation of registers, etc
jay Eclesia: well, I'm working on both using it and working on the bindings.
moritz jay: you can write: my $x := 'foo'; pir::upcase($x)
jay moritz, I'll try that... would give me a 5th example of this same function. 13:58
NotFound_b jay: tip: if you want a quick look of the pir generated for a winxed snippet you can use: winxed -c -o - -e 'some winxed code'
moritz instead of Q:PIR { $P0 = find_lex '$x' \\n %r = upcase $P0 }
jay moritz, I was only trying: my $vec := pir::new("FixedFloatArray", 2); which didn't work, while it did for ResizableFloatArray (without the ,2 of course). 13:59
It's a minor thing, but confusing for a guy like me. 14:00
whiteknight my $vec := pir::new__psi("FixedFloatArray", 2);
if the op can't figure out the types of operands to use, you have to specify
moritz jay: I think you need pir::new("FixedFloatArray"); pir::set__Pi(2) or something
NotFound_b jay: for speed reasons some PMC have a init_int variant, other doesn't.
moritz iirc the fixed*arrays have an API where you use the set_integer vtable for determining the size 14:01
jay < taking notes, will try all these >
NotFound_b I think FixedFloatArray lacks init_int
moritz ah, I only tried it with FixedStringArray
and assumed they all followed the same API 14:02
NotFound_b Uh.... no, it works from winxed.
moritz maybe that was foolish :-)
jay I'll keep each of these (working or not) together for future reference. Might help someone. Maybe I should start blogging.
NotFound_b Ah, yeah, it lacks init_pmc, and that what is nqp is probably generating.
whiteknight jay: We love blogging! 14:03
jay Where is the right place to start blogging for stuff like this? 14:04
JimmyZ nqr.github.com
or nqr.wordpress.com ? 14:05
whiteknight jay: You can open a blog on parrot.org if you don't have infrastructure of your own already set up
That's what several of our GSOC students are doing now
NotFound_b whiteknight: Have you seen the new way of handling builtins? winxed -e 'var say = function(string s){Winxed_Builtins.say("Local say: ", s); }; say("Hi");' 14:12
whiteknight no, what's that about?
I can't just "say('Hello')" anymore?
NotFound_b whiteknight: you can, but you can also redefine them locally. 14:13
whiteknight oh, okay. Cool
Is Winxed_Builtins a namespace?
NotFound_b whiteknight: yes, automatically created and using it in the root namespace.
moritz can you do var Winxed_Builtins = custom_object_with_builtins ?
NotFound_b moritz: not yet, but that feature is a start in that direction. 14:14
Oh, you mean at runtime... yes, it probably works.
jay whiteknight: I have an account on parrot.org, and see bubaflub's blog entries, for example... but don't see how to create my own? Is it on parrotblog.org? 14:15
whiteknight The ability to specify custom builtins, especially as a loadable library, would be awesome
jay: We may need to give you blogging permissions
jay Ah. Username jayemerson
whiteknight jay: What's your parrot.org username? I can add you
jay ^^ 14:16
jayemerson
14:18 woosley joined, dmalcolm joined
whiteknight jay: done 14:19
NotFound_b moritz: well, it may work but it will not override the non namespaced usage, wich is resolved at compile time.
whiteknight reload the page and see if you have any fun new toys
jay ooo... whiteknight++ thanks
whiteknight awesome. Let me know if you have any questions
14:19 GodFather left
dalek website: jayemerson++ | The NQR and GSL Projects 14:22
website: www.parrot.org/content/nqr-and-gsl-projects
NotFound_b The scope search when using and using namespace at different levels are involved can be as confusing or more than C++ ones. But most usages are easy to understand (I hope).
jay Oh boy. My karma is going spat, to three places now.
whiteknight :) 14:23
jay However, the blog working is far more interesting. I'm secure in my karmahood.
whiteknight karma jay
aloha jay has karma of 12.
NotFound_b When in doubt, look at t/advanced/10scope.t and enjoy.
jay karma jayemerson
aloha jayemerson has karma of 1.
whiteknight karma (Jay Emerson)
aloha (Jay Emerson) has karma of 0.
whiteknight karma Jay Emerson
aloha Jay Emerson has karma of 12.
whiteknight karma jayemerson
aloha jayemerson has karma of 1.
jay Still a long way off from the 10,000 needed for a beer... 14:24
whiteknight awesome. So it looks like you're only 9,987 away from a goodie bag of some sort!
Eclesia how much needed for a chocolat ?
karma Eclesia 14:28
aloha Eclesia has karma of 7.
Eclesia :o
14:29 NotFound_b left
dalek R: 3114f3d | (Jay Emerson)++ | / (5 files):
Winxed example working!
14:32
whiteknight Where does that GSL class come from? 14:41
jay Just a namespace in NQR at this point, if that is what you are asking about. Eventually GSL will be a module like bubaflub's GMP. 14:43
whiteknight ok
I just couldn't find where it was defined
jay I guess it is implicitly defined in src/nqr.pir
Remember: you're essentially looking at a hack of squaak. May be very dated. 14:44
whiteknight ok
14:56 Eclesia left
whiteknight hmmm.... I didn't realize we had a uuid library in the parrot repo 15:06
of course, it's fperrad++ so it's not really surprising. He's written so many cool, useful utilities for parrot 15:09
I was thinking about putting together a library for Rosella to do it, but now I don't have ot
to
dalek nxed: ed8699e | NotFound++ | / (3 files):
start providing a version number
15:11
15:16 logie joined
dalek R: 3037a66 | (Jay Emerson)++ | / (2 files):
Adding minor NQR/PIR tests with FixedFloatArray
15:19
benabik ~~ 15:20
jay back again later 15:23
dalek nxed: 4368a1a | NotFound++ | winxedst (2 files):
delete the PMC variant of the sprintf builtin
15:24
nxed: 5b47f58 | NotFound++ | pir/winxed_ (2 files):
update installable files
15:29
15:30 Eclesia joined 15:36 woosley left
dalek nxed/version_1_0: ccf5245 | NotFound++ | / (2 files):
set version to 1.0.0
15:42
15:47 mj41 left 15:48 whiteknight_ joined 15:52 whiteknight left, whiteknight_ is now known as whiteknight
cotto NotFound++ for catching that 15:54
15:59 theory joined
dalek rrot: 67551ad | NotFound++ | ext/winxed/ (3 files):
update winxed snapshot to RELEASE_1_0_0
16:02
NotFound Winxed is ready for the stable release, unless some important bug appears. 16:03
16:06 darbelo joined
dalek rrot: 97325f1 | NotFound++ | ext/winxed/README:
typo
16:06
16:07 logie left 16:09 benabik left
dalek nxed: ee44522 | NotFound++ | / (2 files):
set version to 1.0.0
16:10
16:13 writtencode joined
cotto Is anyone seeing the t/pmc/string.t failure kid51 reported? 16:15
Felipe I see two 'not ok', but they are marked as TODO 16:16
16:18 logie joined
cotto Felipe, are you on a 32-bit Linux distribution? 16:18
Felipe yes
cotto ok. The system kid51 used seems to be some kind of 32-bit linux too. 16:19
Felipe cotto: btw, what is the error?
cotto trac.parrot.org/parrot/ticket/2152 16:20
16:20 cotto left, cotto joined
Felipe ouch 16:21
moderator Parrot 3.5.0 "Menelaus" released | parrot.org | Log: irclog.perlgeek.de/parrot/today | #parrotsketch meeting Tuesday 1930 UTC | Code freeze in effect except for test failure fixes 16:21
16:22 plobsing joined
whiteknight I'm seeing that failure on windows also. I was hoping an update would make it go away, but no 16:23
16:24 JimmyZ left
NotFound That can be related to my change to String.is_integer but I don't see why. 16:25
Felipe I see a failure now. 16:26
t/pmc/threads.t (Wstat: 256 Tests: 14 Failed: 1)
Failed test: 13
whiteknight Felipe: that test is broken. It fails occasionally
Felipe ah
cotto whiteknight, the string.t failure? 16:27
If so, revert and stick it into a branch. We can play with it there.
whiteknight cotto: no, the threads.t failure 16:28
cotto oh 16:29
whiteknight we should have a test to prove that threads.t fails intermittently
cotto TODO: stupid
whiteknight since apparently that is just the status quo
16:29 zby_home joined
cotto FAIL: threads.t did not fail in the last 10 runs 16:30
;)
NotFound I built only optimized since that change... that may explaain something... 16:41
16:43 lichtkind joined
NotFound Yes, reproduced, I'll look at it. 16:43
16:45 daniel-s left
whiteknight cotto: can you do me a favor? 16:47
go fill out your #$^&@# GSOC mentor evaluation
pretty please
bubaflub whiteknight: can i ask you for a favor? (unrelated to above) 16:48
whiteknight bubaflub: sure
bubaflub whiteknight: i need to run and meet someone for lunch so i'll be away for a bit, but if you get a free moment could you look at gist.github.com/1081697 and tell me what exactly my C error is? i'm trying to compile some code generated from parrot_nci_thunk_gen which i've included in the gist. 16:51
whiteknight bubaflub: doesn't look like you are linking to libparrot 16:53
NotFound Oh, shit... found it, my fault. 16:58
cotto whiteknight, done 16:59
whiteknight cotto++
sorry for the curse words.
cotto thanks for agitating
16:59 Eclesia left
cotto whiteknight++ 16:59
I didn't realize until this morning that they were due so soon. 17:00
whiteknight me either. Hence my frenzied emails 17:01
17:02 contingencyplan joined
dalek rrot: 4b344e6 | dukeleto++ | NEWS:
Give NEWS some love
17:05
rrot: 232e4f9 | NotFound++ | src/pmc/string.pmc:
fix String.is_integer method recently added branch for non fixed-8 encodings
17:13
NotFound bubaflub: use -c to compile, if not gcc assume that you want to link a program, not just compile an object. 17:21
bubaflub NotFound: ok. and to link to libparrot do i just need to do -Llibparrot ?
whiteknight I think it's just -Lparrot
bubaflub ok, great. i'll give that a try. 17:22
whiteknight bubaflub: parrot_config should contain all the cc flag sequences you need to build a binary
NotFound bubaflub: you need a main if you want to build an executable.
whiteknight NotFound: he's probably building a shared lib
for NCI stuff
bubaflub whiteknight: yep; that's how i'm doing it now but i don't think i have -Lparrot in there yet.
17:22 mj41 joined
NotFound whiteknight: that's not want the linker says. 17:23
bubaflub whiteknight: i am indeed. i'm kinda groping in the dark on how to do this, so any assistance is welcome. i'm looking at the Makefile but it's a bit dense
NotFound "_main", referenced from: start in crt1.10.6.o
Doesn't look like a shared lib
whiteknight NotFound: I'm sure a shared lib is his intention, and the linker commandline is missing some details 17:24
bubaflub NotFound: i'm trying to compile the output of parrot_nci_thunk_gen, lemme check what i get frmo there 17:25
whiteknight bubaflub: like I said, look at some of the keys in parrot_config
NotFound There is not an automated way to do that? I don't think we expect people provide his linking instructions for such a thing. 17:26
whiteknight Your commandline will probably look something like this: ${parrot_config "cc"} ${parrot_config "cc_flags"} ${parrot_config "cc_inc"} ... 17:27
NotFound: I think I want to put together a program to compile things like this 17:28
it's so common to do, and a driver program to put all the pieces together would be very helpful
bubaflub whiteknight: you're right, it's embed-ldflags 17:29
whiteknight bubaflub: look through runtime/parrot/library/distutils.pir and find the places where it's building dynpmcs. Copy all that logic
NotFound embed? That's not embedding! 17:30
whiteknight the config hash is filled with fail 17:31
bubaflub ah, inst_libparrot_linkflags might be a better choice 17:32
or even just libparrot_linkflags
17:33 mj41 left
cotto string.t failures: smolder.parrot.org/app/projects/tes...tory/1/224 17:39
whiteknight I would very much like to see the config hash removed from Parrot entirely 17:40
The only parts of it that are used by Parrot core are the include and load search paths
And a much smaller mechanism could be devised to provide that information 17:41
The config hash should be provided as a separate .pbc, to be loaded on demand if we need the crap it contains
bubaflub whiteknight: i agree. there are lots of duplicates in there, also according to chromatic's performance wiki page it slows Parrot start up 17:42
whiteknight: also, all of that information in one config hash forces it to be all configure time information - maybe we want values from what we are currently running on, not what we compiled on 17:43
dukeleto NotFound: congrats on winxed 1.0.0 ;)
17:43 benabik joined
NotFound Ah, the magic of version numbers ;) 17:43
dukeleto whiteknight: we definitely need to take into account how others use our config hash. For instance, PL/Parrot's build uses various config keys 17:44
whiteknight: but I mostly agree. The current situation is sucky
whiteknight dukeleto: I'm not saying make it disappear, I'm saying not to make it a built-in part of libparrot. We should be able to load it on demand, not be forced to always keep a copy of it around
dukeleto whiteknight: +1 17:45
whiteknight a hash with 200+ keys, the vast majority of which are rarely or never used, isn't something we should be loading eagerly
NotFound And complicates linking, too.
whiteknight right. That's the entire reason for miniparrot 17:46
dukeleto this README is pretty hilarious github.com/spencertipping/rift
bubaflub whiteknight: i think we can safely prune some of the items and de-duplicate. splitting into different hashes (one with build info and one with other info) would be a bigger change.
whiteknight we can cut that whole build step out
bubaflub: I'm saying we just pull the whole thing out
bubaflub whiteknight: even better. 17:47
whiteknight bubaflub: like I said, the only things we currently need from that hash are the library search paths
and we can find a different way to supply them.
NotFound The 'other info' can be provided by a pir library.
whiteknight Maybe a config file that goes with the install, and is only read when we call load_bytecode or attempt an .include
more lazy == more good 17:48
NotFound whiteknight: but to read it, we need the search path ;)
dukeleto whiteknight: but that is pretty much all the time
dalek rrot: 82e6c72 | NotFound++ | src/pmc/bytebuffer.pmc:
ByteBuffer vtable get_pointer
17:50
dukeleto NotFound: adding new features to master right now (especially without tests) is going to give kid51++ a sad face 17:51
NotFound dukeleto: I'm sorry, I thought I was already added it before, but kept forgotten. 17:52
whiteknight NotFound: There's no difference between serializing the config hash into the libparrot binary, or just writing in a few constant strings into the libparrot binary
in both cases, we have constants in the binary. In the second case, we aren't fiddling with hashes and STRING* to do it
dukeleto NotFound: not a huge deal, but a simple test for that would be greatly appreciated
NotFound dukeleto: that's not easy. A test for that may need a nci call, wich is not easy to do portably in a test. 17:54
bubaflub whiteknight: i'm getting this warning but everything compiles; should i be worried: i686-apple-darwin10-gcc-4.2.1: -lparrot: linker input file unused because linking not done 17:55
whiteknight bubaflub: what does it compile to? Is it compiling to .o or .so?
or, whatever the equivalents are on mac
bubaflub .o
NotFound Then the compiler tells the truth. 17:56
whiteknight bubaflub: right, so now get it linked 17:57
bubaflub whiteknight: i'm a bit confused. i thought i was getting it compiled and linked... 17:59
whiteknight bubaflub: what compiler are you using? 18:00
NotFound bubaflub: if you use -c as I told you, you are compiling.
whiteknight .o is just an object file, not a binary
bubaflub NotFound: i am. here is the command line invocation (it's long): cc -fno-common -no-cpp-precomp -pipe -fstack-protector -I/usr/local/include -pipe -fno-common -DHASATTRIBUTE_CONST -DHASATTRIBUTE_DEPRECATED -DHASATTRIBUTE_MALLOC -DHASATTRIBUTE_NONNULL -DHASATTRIBUTE_NORETURN -DHASATTRIBUTE_PURE -DHASATTRIBUTE_UNUSED -DHASATTRIBUTE_WARN_UNUSED_RESULT -I/usr/local/Cellar/libffi/3.0.9/lib/libffi-3.0.9/include
-I/usr/local/include/parrot/3.5.0-devel -L"/Users/bob/Desktop/work/parrot/blib/lib" -lparrot -Ipmc/pmc_nci.h -o src/GMP/thunks.o -c src/GMP/thunks.c
18:01 awwaiid left
whiteknight the -o part is specifying an object file to create, not a binary 18:01
you're telling it to make thunks.o, not thunks.so
18:01 awwaiid joined
bubaflub whiteknight: sorry i'm so clueless when it comes to C; will i need to call ld next? 18:03
whiteknight bubaflub: it's okay. Like I said, you're going to have to look at distutils.pir to find out how it builds dynpmc shared libraries 18:05
it will contain all the magic, just copy that
bubaflub whiteknight: yup, just found it. line 1442. 18:06
whiteknight awesome 18:07
cotto_work ~~ 18:08
dukeleto cotto_work: wilkommen
cotto_work dukeleto: halo 18:10
18:16 Coke left
bubaflub whiteknight: booyah. now i've got thunks.bundle (which i believe is what the shared library stuff is on Mac) 18:17
now i just need to figure out what to *do* with it. 18:19
18:19 Coke joined
whiteknight bubaflub: whoa whoa, we're making software here, not philosophy 18:20
like, what is the purpose of anything, man? 18:21
bubaflub whiteknight: that's heavy.
whiteknight: i was thinking more of how do i load this such that i don't need libffi. 18:22
whiteknight oh, you use the loadlib op, or whatever it is 18:24
winxed may have a $loadlib directive
bubaflub i believe it does.
plobsing bubaflub: you need to loadlib the thunk library. If you've used the magic loader name (whose format escapes me at the moment), parrot should run the loader automagically, and the thunks will just be there 18:25
bubaflub plobsing: in the parrot Makefile there is just --dynext --no-warn-dups, i was hoping it would just run with that 18:26
plobsing bubaflub: it should work with that 18:28
you can use 'nm' to find the name of the loader function and then gdb to determine if it is being called
bubaflub plobsing: woot.
plobsing *if it does not work at first
bubaflub whiteknight: i'm having some trouble installing rosella from plumage; Null PMC access in set_string_native(), setup.winxed:339 18:29
dalek nxed: 6108d36 | NotFound++ | examples/Mysql.winxed:
fix a bug in native string conversions in Mysql example
18:30
TT #2152 closed by jkeenan++: t/pmc/string.t, t/library/streams.t: new test failures 18:33
TT #2152: trac.parrot.org/parrot/ticket/2152
whiteknight bubaflub: weird, I'll have to look at it tonight when I get home 18:35
bubaflub whiteknight: ok, i'm hacking on it 18:36
whiteknight: it has to do with the sprintf("%s%s.pasm", [..., ...]); line
whiteknight okay 18:39
bubaflub whiteknight: actually, it might be my setup... i think i need to clean out my parrot and plumage and start over. 18:40
dukeleto bubaflub: that is caused by doing a partial recompile after updating 18:43
bubaflub: git clean -fdx and try again
bubaflub dukeleto: ok
dukeleto bubaflub: git clean rm's files
bubaflub is that better than make realclean?
dukeleto bubaflub: make sure there aren't any uncommitted files before running that
bubaflub git stash to the rescue
dukeleto bubaflub: i still had the same problem when trying "winxed setup.winxed clean build"
bubaflub dukeleto: ok, i'll do that 18:45
18:48 dodathome left
bubaflub whiteknight: false alarm, that fixed it. 18:52
well, now i have an entirely different problem
src/namespace.c:367: failed assertion 'pmc_key'
when trying to run any of my winxed tests
18:54 particle left
NotFound Oh, shit, another nice problem with nci and encoding: I can't use Parrot_str_new_init beacues it needs a length, and I can't get the c sring length from an UnManagedStruct 18:54
dukeleto bubaflub: i know about that too ;)
bubaflub dukeleto: do tell.
dukeleto bubaflub: that is caused by winxed being compiled by a different parrot than you are trying to comiple rosella with
18:55 particle joined
dukeleto bubaflub: that happened to me when the parrot that rakudo installs was in my path 18:55
bubaflub dukeleto: hmm... ok, lemme try and nuke winxed
dukeleto bubaflub: winxed gets installed when you install parrot. did you install a different one?
bubaflub dukeleto: no, i think i just have old PBC lying around. 18:56
dukeleto NotFound: other languages prefix parrot in their binary name. like parrot-nqp. Any good reason that winxed doesn't?
bubaflub dukeleto: phew, all is well in the land of Parrot-GMP again. 18:57
NotFound dukeleto: any good reason to do it?
bubaflub: there was a problem with the builtin sprintf in winxed, you need to update 18:59
bubaflub NotFound: ok.
dukeleto NotFound: not sure, but all other things in parrot do it, and winxed is now changing that pattern 19:00
benabik is busy converting NQP to PIR. It feels wrong. 19:02
NotFound dukeleto: winxed is the only winxed compiler in the world, there are no possible confusions.
dukeleto NotFound: there is "the latest winxed release" and there is "the winxed that came included with parrot". There are at least 2 now.
19:03 darbelo left 19:04 hercynium joined
NotFound dukeleto: in order to use winxed from other sources either you need to use build tree, in wich case you should know what you are doing, or you need to install it in parrot. 19:04
dalek L: ee2f8bf | (Jay Emerson)++ | / (2 files):
Documented configuration improvements in line with bubaflub++
19:05
NotFound And if you install it, no matter what names you use for the driver, the load_language name must be the same.
dalek p: 6a6285f | pmichaud++ | src/QRegex/P6Regex/Actions.nqp:
Remove some debugging output.
p: 30ed7ec | pmichaud++ | src/ops/nqp.ops:
Add nqp_radix opcode for simplifying string->number conversions.
p: 0eea302 | pmichaud++ | src/ops/nqp.ops:
Fix underscore bug in nqp_radix opcode.
NotFound nqp does different things... and the result is that you can't load_language 'nqp' 19:06
benabik If I want to create a closure that uses the current lexical scope, do I have to use newclosure and capture_lex, or does newclosure handle it for me?
My other questions would be "how do I get a sub pmc"? 19:07
NotFound benabik: newclosure do it 19:08
benabik: if you get the sub, it's already a Sub PMC 19:10
benabik NotFound: How do I get the sub?
NotFound benabik: if it's in the current PIR, you can just use its name or subid. 19:12
Or you can use get_global and family. 19:13
benabik newclosure 'sub_name' ?
PIR confuses me.
whiteknight benabik: the source for the opcodes in question can be very instructive. src/ops/core.ops, I think, contains definitions for newclosure and capture_lex
NotFound benabik: winxed -c -o - -e 'var i; var f = function() { say(i);};'
That will show you what winxed does. 19:14
19:14 darbelo joined
NotFound (the var i is to force the anon function to be a closure) 19:16
benabik NotFound++ 19:19
NotFound I wrote winxed mostly to never need to write such things by hand ;) 19:20
benabik Well, yes. But I don't want to waste more time converting all of PCT::HLLCompiler to NQP or Winxed. 19:22
benabik is adding a 'pbc' stage to HLLCompiler...
dukeleto benabik: what is your current worry? 19:23
NotFound benabik: no, but you can use winxed as helper, as I've just done right now.
benabik NotFound: indeed. winxed++ 19:24
NotFound You still need to write, but a least you don't neeed to have that gory details in your head.
benabik dukeleto: Current worry?
dukeleto benabik: you sound worried :) 19:37
benabik dukeleto: Ah. I'm trying to figure out wedging PBC generation into the PCT tests. It's interesting to say the least. 19:38
Coke www.google-melange.com/gsoc/grading...11/midterm is a 404. 19:43
so, I can't file a midterm eval. 19:45
benabik Coke: I don't know if the site is different for mentors, but I found the midterm under my dashboard. 19:46
dukeleto Coke: that URL is probably not valid for a mentor
Coke: if you login, you should have some kind of notice
Coke ah. further in the thread was a note that the link carol sent out didn't work.
benabik++ 19:47
cotto_work Coke: you're happy now?
19:50 bluescreen left 19:51 bluescreen joined 19:52 telemachus_ joined
telemachus_ hmm 19:52
19:53 telemachus left, telemachus_ is now known as telemachus, mtk left 19:54 logie left, loganbell joined, loganbell is now known as logie
Coke cotto_work: as happy as I get. 19:55
19:57 mtk joined, telemachus left, particle1 joined 19:58 mj41 joined
cotto_work Coke: wfm 20:00
20:01 particle left
whiteknight Coke: We need to find a way to raise the maximum limit 20:02
dalek kudo/nom: f7e4cec | moritz++ | src/Perl6/Actions.pm:
(re-)introduce radcalc, but smarter than before
20:04
kudo/nom: 64fe676 | moritz++ | src/Perl6/Actions.pm:
allow arbirary number of trailing zeros. Wins back the few tests that the previous commit regressed
kudo/nom: 8097419 | moritz++ | src/Perl6/Actions.pm:
hopefully speed up stripping of trailing zeros
kudo/nom: 09a43b7 | moritz++ | src/Perl6/Actions.pm:
remove (mostly PIR) functions that are now mostly unused
kudo/nom: e939a8b | moritz++ | src/Perl6/Actions.pm:
get :16<DEAD_BEEF> style literals working
kudo/nom: 01df600 | moritz++ | src/Perl6/ (2 files):
refactor numeric constants to do the PAST::Want magic in a single place
kudo/nom: 9c93942 | moritz++ | src/Perl6/ (2 files):
Merge branch 'nom-num' into nom
kudo/nom: 76d6591 | moritz++ | t/spectest.data:
remove testfile from spectest.data, because it is gone from roast
20:07 mtk left, perlite left 20:09 mtk joined, perlite joined
dalek R: f68c298 | (Jay Emerson)++ | / (4 files):
Updated silly examples of the calls
20:13
kudo: 1ddda5e | moritz++ | build/Makefile.in:
track branch rakudo-master of the roast repository
20:14
jay PIR philosophy or internals: is there a difference in the way a ResizableFloatArray and a FixedFloatArray store the data? Or is the difference only in the away they are initialized (with subsequent resizing then allowed or not)? 20:16
dukeleto jay: i know what you are asking about 20:20
jay: RFA's take up more space, and are slower 20:21
20:21 Coke left, Coke joined
jay If it's too deep or doesn't matter, that's ok. I'm just wondering if I pass a pointer to the data of a RFA will I risk segfaulting in some C library? 20:21
I trust FFAs are safe in that respect.
dukeleto jay: FFA's take up less, space, and are faster. Both should allow being created, with the size of it being given. You got an error about init_pmc not being defined for one of them?
jay: are you only reading from the RFA data? What exactly are you doing? 20:22
Coke whiteknight: what limit?
jay No, I think I've cracked that nut with help from folks. I might be reading or writing I suppose. Trying to decide if I want a class 'vector' that only uses FFAs, or if it really matters.
dukeleto jay: also, whiteknight++ has something called parrot-data-structures which implements lots more kinds of datastructures. 20:23
jay But I need to pass pointers to the data to other libraries (along with the length) and not crash.
Ah -- that I should look at methinks.
dukeleto jay: you should copy the data, then pass it along. Other libraries should not be modifying Parrot objects.
jay: that will surely lead to segfaults 20:24
jay: github.com/whiteknight/parrot-data-structures
jay: sparse arrays will probably be very useful for you
jay Er, well, yes and no. I'm ultimately thinking of very big things that I do NOT want to copy. And I do want to modify, albeit very carefully. Surely that wouldn't segfault. 20:25
No, I know about sparse arrays. Fine, not not what my focus is.
dukeleto jay: i guess if you don't modify the metadata of the parrot object, and you are only changing some values in the array, that should work 20:26
jay: but if you accidently corrupt tha parrot object metadata, badness will occur
whiteknight ResizableFloatArray inherits from FixedFloatArray, but provides resizing behavior instead of bounds-check-and-error behavior 20:27
jay Right, exactly. In R there is no notion of "resizable" by the way. Don't need it. And the external libraries would only get the pointer to the data, not the metadata.
whiteknight in reality, the two types are almost identical, except a few small differences and a huge amount of unnecessary duplication
jay whiteknight... ok, that sounds completely reasonable.
whiteknight Personally, I would love to cut the crap and have a single "FloatArray" type that can resize or not depending on settins
jay But for efficiency reasons it sounds like I might as well just use FFAs. 20:28
whiteknight jay: for your purposes, the two types use a malloc'd memory buffer that is a simple C FLOATVAL array
jay: besides resizing behavior, the two are exactly the same
you can pre-size a ResizableFloatArray, and get exactly the same performance out of it
jay Yup, good. Eventually I'll want to memory-map, and i have notes from you (I think) on MappedByteArray that I need to look at, too. 20:29
20:29 ambs left
whiteknight FixedFloatArray actually can resize, by calling set_integer_native. The difference is that FixedFloatArray requires you to do this manually, ResizableFloatArray does it automatically. Otherwise, no difference 20:29
And since both types need to bounds check to determine behavior on overflow, the performance should be identical
jay Ok, maybe dukeleto was thinking about some other aspect of them. 20:30
whiteknight anyway, I'm heading home now. Talk to you later
20:30 whiteknight left
jay thanks! whiteknight++ 20:30
dukeleto++ thanks, too. I like the phrase "badness will occur." I'll try to avoid that.
20:30 particle joined
dukeleto jay: whiteknight probably knows better. I assumed FFA's were faster. But only a benchmark can tell the truth 20:30
jay ok 20:31
dukeleto jay: i am pretty good at making badness occur, so I try to warn others :)
jay: it is really nice to see your GSL bindings coming along. I have been wanting to write that for a long time, and now I don't have to ;) 20:32
cotto_work dukeleto: any thoughts on the new M0 ops I added last night?
dukeleto cotto_work: didn't see them yet 20:33
cotto_work use bytes; is fun\\
20:34 particle1 left
NotFound dukeleto: it needs to do bound checking anyway, there is no pssible shortcut to make it faster that the resizable variant. 20:34
dukeleto cotto_work: i see the value in them.
cotto_work: they would be quite useful for m0 strings 20:35
cotto_work dukeleto: that's the exact use case I'm thinking of.
dukeleto: the question I have is whether there's a better way to get that functionality. I suspect not, but I don't know for sure. 20:36
I'm writing a quick example to see what it's like to actually use them.
dukeleto cotto_work: i like it 20:38
20:40 darbelo left
cotto_work dukeleto: thanks 20:41
dukeleto jay: according to examples/benchmarks/array_access.pir --arr-size=2000 , there is about a 5% performance penalty for ResizableFloatArray vs. FixedFloatArray 20:43
jay: which is for arrays of size 2000
20:43 ambs joined
dukeleto jay: gist.github.com/1083395 20:43
jay Gotcha. Not an order of magnitude, then. 20:44
Err... is it backwards? FixedFloatArray: 0.824878931045532s vs ResizableFloatArray: 0.782232999801636s? FFA is slower (this is the 2000*1000 case)? 20:46
dukeleto jay: also, as arrays get larger, the penalty goes down. arrays of 10000 there is only a 1% penalty
jay Yes... fixed cost of doing business gets washed out. 20:47
dukeleto jay: gist.github.com/1083408 20:49
jay: that shows it 1% the other way for arrays of size 10,000
jay Yup. Small. So I'll think about design rather than performance. 20:50
20:50 plobsing left
dukeleto jay: one thing to note is that PMCArrays are much slower. Stay away from them unless you really need them. 20:50
jay: does R have the concept of an "object" ?
jay: or is everything a vector? does it differentiate between vectors and matrices? 20:51
jay I'd use them for something I would call a data.frame (yes, it does, dukeleto), which is a list of vectors of possibly different types.
dukeleto mostly used matlab and mathematica in previous lives
jay An array is a vector with a dimension attribute.
You can make a vector into an array just by changing the dim attribute, without making a copy.
(as long as the conversion makes sense) 20:52
20:52 darbelo joined
jay So I was thinking a data.frame would be a PMC array containing things like FFAs and FIAs and FSAs. 20:53
Coke is so sick of gsoc mentor mailing list drama. 20:54
(not just this year. just years and years of it.)
cotto_work I solve that problem by almost completely ignoring it. 20:55
almost
21:05 soh_cah_toa joined
soh_cah_toa ~~ 21:05
Coke mmmm. 21:06
dukeleto Coke: i solve it by completely ignoring it 21:10
jay: PMCArrays are fine for a few elements. But creating large PMCArrays should only be done if you actually need a PMCArray, is all I meant to say 21:11
jay Ok. I'll revisit this once I get through some of the more basic stuff. !-) 21:12
dukeleto jay: keep on truckin'!
i must say, melange has come a long way. I actually have an "org admin dashboard" now
Felipe where is the gsoc project list? 21:14
I see 21:15
21:29 fperrad left
dukeleto soh_cah_toa: ping 21:29
soh_cah_toa dukeleto: pong
dukeleto soh_cah_toa: i am getting emails about you not having done your eval yet. Why do you hate my inbox? 21:30
cotto_work Think of the dukes.
dukeleto soh_cah_toa: the eval takes 1 minute
21:30 ambs left
dukeleto soh_cah_toa: i just did mine. 21:30
cotto_work It was much easier than I was expecting.
soh_cah_toa dukeleto: well, i was putting it off but i'm doing it now
21:30 mj41 left
dukeleto soh_cah_toa: good to hear :) 21:31
Felipe: are you the same felipe that recently fixed a memory leak in imcc? if so, nice work! 21:38
Felipe it's me
thanks :) 21:39
too much code to read, to much files!
:D
21:43 Psyche^ joined
dukeleto Felipe: are you using valgrind to find leaks? 21:45
benabik Huh. I ended up losing the converted pbc stage method. Guh.
Felipe dukeleto: yes. 21:46
dukeleto Felipe: awesome. just wondering. 21:47
jay Resizable*Array inherits from Fixed*Array.... does Fixed*Array then inherit from array? Hence pir::does($arg, "array") succeeds for both? 21:48
21:48 Patterner left, Psyche^ is now known as Patterner
dukeleto jay: i dont' think we have a plain Array PMC 21:48
benabik So I get to write all the PIR again. Joy.
dukeleto jay: they both probably inherit from the Default PMC
benabik: how do you lose stuff? 21:49
benabik dukeleto: I really don't know. I think I mis-used git-stash.
It's probably _somewhere_ in my git objdb, but I don't know where.
dukeleto benabik: git reflog ?
which should be called, git savemyass 21:50
benabik dukeleto: I didn't commit it... Which is really my mistake.
dukeleto: I had stashed it, but it doesn't appear to be in my stashes.
dukeleto benabik: were you working on a differnt machine? I switch between so many machines that sometimes a branch is not where I remember it 21:51
benabik dukeleto: Nope. Just have the laptop. I was just dumb.
I know how to write it now, so it should be fast.
dukeleto benabik: good perspective to have :) Buena suerte!
21:58 dmalcolm left
jay Are the literal types (Integer, String, Float) technically classes? I'm guessing maybe not. 22:10
sorear How do you mean? 22:11
jay So I could create a class 'integer' containing an Integer, and then something else could inherit from class 'integer'... just guessing.
sorear We have classes named Integer, String, and Float
it's also possible to create native registers of those types, which are *not* classes
jay Or can I do 'Boolean is Integer', where Boolean is my new type, inheriting from Integer? 22:12
cotto_work You could if we didn't already have one.
sorear jay: what language are you using?
I think it needs to be Boolean extends Integer for pmc2c 22:13
jay Writing an HLL. I see PIR docs on classes and subclasses. Are there docs for NQP-rx or Winxed on this stuff? Or good example code to look at? I didn't see subclass material in bubaflub's stuff.
sorear you need to know that Parrot has two largely independant class/object systems 22:14
jay Uh oh
sorear the primitive classes are called pmclasses, they include Integer, String, Float, etc
there are 2 special pmclasses, Class and Object, which implement a *second* object system 22:15
most HLLs work only with instances of Object
pmclasses can only be created using C code with the pmc2c preprocessor; PIR generates Class instances 22:16
there's special magic to allow Classes to inherit from pmclasses, but it's slow and semantically horrible 22:17
benabik 's git-fu is weak today.
sorear NQP contains a third object system, based on the SixModelObject pmclass 22:18
NotFound jay: in winxed to inherit from a PMC you can do: class MyInteger : ['Integer'] { ... }
Felipe dukeleto: did you changed the NEWS file mentioning the leak? 22:19
dukeleto Felipe: yes, i added it to NEWS
Felipe dukeleto: but it was not merged yet
jay NotFound: ok, that looks hopeful. sorear: I sort of follow, and need to be more aware. Again, any doc recommendations are always appreciated.
dukeleto Felipe: i thought that I saw the pull request get closed. Did it get pulled into a branch other than master? 22:20
Felipe dukeleto: nop, the close was my mistake. I opened it in the morning. 22:21
22:21 whiteknight joined
Felipe never had used this pull request stuff before :p 22:22
dukeleto Felipe: ah 22:23
Felipe: i am running tests on my machine and will merge it if everything looks good 22:28
Felipe dukeleto: thanks, sorry for the confusion :) 22:29
dukeleto Felipe: no worries, pull requests are slightly confusing at first, but they are really quite awesome 22:30
benabik Yay! t/compilers/pct/complete_workflow.t is now failing! 22:37
whiteknight failz
benabik Well, to be more specific, it's now failing in the way I needed it to. 22:38
Namely failing because it doesn't know how to compile to PBC correctly.
22:39 bubaflub left
whiteknight oh, this is in your branch? 22:40
benabik Yes.
dalek rrot: 6623080 | (Felipe Pena)++ | compilers/imcc/imcc.l:
- Fixed memory leak on imcc_compile_buffer_safe() function (#2141)

Signed-off-by: Jonathan "Duke" Leto <jonathan@leto.net>
22:42
rrot: a792bdd | (Felipe Pena)++ | compilers/imcc/imclexer.c:
- Regenerated imclexer.c file

Signed-off-by: Jonathan "Duke" Leto <jonathan@leto.net>
rrot: 6c82876 | dukeleto++ | compilers/imcc/imc (2 files):
Merge branch 'fix_imcc_memory_leak'
dukeleto make fulltest passed for me, and it was a bugfix, so i decided that it was OK to merge to master 22:43
cotto_work dukeleto: wfm 22:49
dukeleto Felipe: ok, NEWS is correct now :) 22:51
Felipe: and congrats to getting your first patch accepted
Felipe: i am excited to see more :)
22:53 whiteknight left, whiteknight joined
dalek p: 134720b | pmichaud++ | src/ (2 files):
Add a few more useful option flags to nqp_radix opcode.
22:57
22:57 whiteknight left
22:57 whiteknight joined 23:06 soh_cah_toa left
dalek kudo/nom: 3cf23af | pmichaud++ | / (3 files):
Update Str.Numeric to be a lot more correct. Numifying strings now

code is intended to handle the common cases; uncommon cases are likely to ultimately be handled by the compiler somehow.
23:08
23:21 kid51 joined, zby_home left 23:22 soh_cah_toa joined
soh_cah_toa ~~ 23:23
Felipe dukeleto: :D 23:24
23:24 hercynium left
dalek website: NotFound++ | Winxed 1.0.0 23:25
website: www.parrot.org/content/winxed-1.0.0
23:28 whiteknight left 23:30 bluescreen left 23:31 kid51 left 23:33 kid51 joined
jay Question: In the Ch 4 of the pir book, I quote "The array types that include "String", "Integer", or "Boolean" in the name use alternate packing methods for greater memory efficiency." Does this mean I can't depend on a FixedIntegerArray of length N actually being N*sizeof(int) bytes long? 23:35
Sounds like a recipe for a segfault if I'm passing a pointer to the data in a FixedIntegerArray to some external library. 23:36
NotFound jay: is not int, is INTVAL. It may be the same as int, or not. 23:37
soh_cah_toa jay: if you need the length of a Fixed*Array, use the elems() method 23:38
i think that's it's name, let me double check
jay ok. I don't want that soh_cah_toa, I'm passing the data to an external C function.
sorear jay: what that sentence means is that FixedIntegerArray does not contain PMCs 23:39
soh_cah_toa eh...
jay sorear: ok. Any reason not to say that -- seems not at all clear to me.
soh_cah_toa oh really? i always assumed Fixed*Array meant that it used the * pmc. never new that 23:40
*knew
jay Second suggestion, if someone is taking notes: FixedBooleanArray is there, and I'm interested in Boolean, but Boolean doesn't get any mention as one of the atomic types in the material up to that point. Would be an easy addition. 23:41
Or I'd be happy to do something with these suggestions, if there is a "recommended" way to contribute?
soh_cah_toa jay: that pir book is actually very old and not worked on much any more. though i would love to see it updated 23:42
sorear jay: boolean is *not* an atomic type 23:43
jay Well, I expect it is a PMC with a class probably inheriting from Integer. And integer is a PMC that is a "thin layer" over a literal integer? Or am I wrong? 23:44
< sorry, first integer should have been Integer >
NotFound BooleanArray is a bag of bits
jay Ah -- you really pack them?
Not sure the memory savings is worth the overhead in this day an age, but fine. 23:45
So there is no Boolean in isolation that is the counterpart of Integer, Float, and String PMCs... hence not really discussed until you get into the Aggregates liek FixedBooleanArray? 23:46
NotFound Yes, there is one. But is not directly related to the BooleanArray types. 23:47
The other Array aren't also directly related to its non array counterparts. 23:48
jay Ok. I'm happy leaving it for now, then. Thanks. I think I have what I needed... that original confusion over what was meant by " alternate packing methods for greater memory efficiency".
NotFound I think that this just means that they are not PMC arrays. 23:49
23:49 bluescreen joined
jay Ok. Any thoughts on a formal doc effort? There is something nice about the "example-based" approach, often... but not always. 23:51
You might even get me to help... since I'm asking a lot of questions anyway.
sorear jay: interpreters for garbage-collected languages tend to be limited by cache bandwidth, so memory savings are direct speedups 23:52
NotFound jay: most of us are coders by heart, we usually spend more time in the code than in documenting how to use it.
jay I understand. It does mean you'll continue to get questions that might otherwise have been answered in formal docs. That will eventually wear you out. 23:53
soh_cah_toa indeed
jay I actually thing there are decent materials out there, but I'm having a hell of a time finding where I need to be, often.
< think >
soh_cah_toa has the same experience on a daily basis 23:54
NotFound jay: My approach is to make the language easier to read, thus decreasing the number of questions ;)
jay That's a very worthy goal, no question. I've learned a lot (though not enough) about Winxed by reading bubaflub's code. I need either more formality... or more similar blocks of code I can chew over in a helpful way. 23:55
Maybe I should start. NotFound: is there any real doc effort for Winxed underway? If not, could I start it? 23:56
dalek TT #920 closed by jkeenan++: parrotbug should provide more guidance when it finishes 23:57
TT #920: trac.parrot.org/parrot/ticket/920
NotFound Unfortunately the winxed compiler is not a very good example, beacaus it must restrict the syntax used to be compilable by stage 0.
jay: whitenight has been wrtiting some documentation. 23:58
jay Maybe I'm at a different level. I only care about writing Winxed as an attractive alternative to NQP for building an HLL, but I need to know how the variable types, classes, etc... related to the underlying PIR ultimately. Without guessing.
23:58 bubaflub joined
NotFound I don't have the url at hand because winxed.org is having problems. 23:58
Let me look at my copy... 23:59
Found: whiteknight.github.com/Rosella/winxed/index.html
bubaflub jay: that's where i go for all my Winxed needs