Re: More thougths on DOD
Mitchell N Charity wrote: The attached patch adds a scheme where: - gc flags are in the pool, and - pmc->pool mapping is done with aligned pools and pmc pointer masking. Thanks for that. Observations: - It's fast. (The _test_ is anyway.) Perhaps 4x random, 10x+ linear. I see ~8x/~12x with pmc->pool calculation on my Athlon with -O3. - PMC size doesn't matter here, because we never actually touch them. Yep, for marking. Putting the PMC on the free_list then would still be cheaper for smaller PMCs I think. Mitchell (I assume at some point Dan will say "ok, we've demonstrated the minimally required gc performace... so now let's get back to actually writing the thing...". That will quiet my currently fluttering premature optimization warning flags. ;) I think, we should have some schemes in parallel. I have here my "small PMC" patch (though w/o morphing or such), separated flags shouldn't be too hard due to the flag accessor macros. Do we already have a general purpose memalign() function and a config test for it - or better, was there some in past? leo
Re: More thougths on DOD
Attached test program shows some additional effects of PMC size and
timing. [...]
Nifty.
The attached patch adds a scheme where:
- gc flags are in the pool, and
- pmc->pool mapping is done with aligned pools and pmc pointer masking.
Observations:
- It's fast. (The _test_ is anyway.) Perhaps 4x random, 10x+ linear.
- PMC size doesn't matter here, because we never actually touch them.
Mitchell
(I assume at some point Dan will say "ok, we've demonstrated the
minimally required gc performace... so now let's get back to actually
writing the thing...". That will quiet my currently fluttering
premature optimization warning flags. ;)
--- tpmc.c Mon Jan 6 14:55:14 2003
+++ r02.c Mon Jan 6 17:24:32 2003
@@ -52,6 +52,11 @@
int fill[3];
} SPMC;
+struct pool_pmc {
+char *flags;
+PMC mem[1];
+} * pool_pmc[N];
+
int main(int argc, char *argv[])
{
@@ -152,6 +157,76 @@
rdtsc(&b);
printf("%d empty ticks %10ld\n", i, b - a - e);
+/* alternate aligned pool with sep flags */
+
+#define SIZE2 (SIZE-1)
+#define ALIGN (SIZE*(8*sizeof(int)))
+for (i = 0; i < N; i++) {
+pool_pmc[i] = memalign(ALIGN, SIZE*sizeof(PMC));
+pool_pmc[i]->flags = calloc(SIZE, sizeof(char));
+/*printf("pool %d %p\n", i, pool_pmc[i]);*/
+}
+
+for (n = 0; n < 3; n++) {
+rdtsc(&a);
+for (j = 0; j < N; j++) {
+l = (int) ((double)N * rand()/(RAND_MAX+1.0));
+for (i = 0; i < SIZE2; i++) {
+k = (int) ((double)SIZE2 * rand()/(RAND_MAX+1.0));
+pool_pmc[j]->flags[i] |= 1;
+}
+}
+rdtsc(&b);
+printf("%d linear PMC sep-flags flag-only ticks %10ld\n", i, b - a - e);
+
+rdtsc(&a);
+for (j = 0; j < N; j++) {
+l = (int) ((double)N * rand()/(RAND_MAX+1.0));
+for (i = 0; i < SIZE2; i++) {
+k = (int) ((double)SIZE2 * rand()/(RAND_MAX+1.0));
+pool_pmc[j]->flags[k] |= 1;
+}
+}
+rdtsc(&b);
+printf("%d random PMC sep-flags flag-only ticks %10ld\n", i, b - a - e);
+
+#define P2I(ptr) ((unsigned long)(ptr))
+#define CALC(ik) \
+{ \
+PMC *ppmc = (PMC*)&(pool_pmc[j]->mem[(ik)]); \
+struct pool_pmc *pool = ((struct pool_pmc *) \
+ (P2I(ppmc) & ~(ALIGN-1))); \
+size_t n = ((P2I(ppmc) - P2I(&(pool->mem[0]))) \
+ /sizeof(PMC)); \
+/*printf(">> pool %d %p pmc# %d %p ->pool %p pmc# %d\n", \
+ j,pool_pmc[j],i,ppmc,pool,n);*/ \
+pool->flags[n] |= 1; \
+}
+
+
+rdtsc(&a);
+for (j = 0; j < N; j++) {
+l = (int) ((double)N * rand()/(RAND_MAX+1.0));
+for (i = 0; i < SIZE2; i++) {
+k = (int) ((double)SIZE2 * rand()/(RAND_MAX+1.0));
+CALC(i);
+}
+}
+rdtsc(&b);
+printf("%d linear PMC sep-flags PMC->flag ticks %10ld\n", i, b - a - e);
+
+rdtsc(&a);
+for (j = 0; j < N; j++) {
+l = (int) ((double)N * rand()/(RAND_MAX+1.0));
+for (i = 0; i < SIZE2; i++) {
+k = (int) ((double)SIZE2 * rand()/(RAND_MAX+1.0));
+CALC(k);
+}
+}
+rdtsc(&b);
+printf("%d random PMC sep-flags PMC->flag ticks %10ld\n", i, b - a - e);
+
+}
return 0;
}
[perl #19800] LOL
# New Ticket Created by ([EMAIL PROTECTED]) # Please include the string: [perl #19800] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt2/Ticket/Display.html?id=19800 > Below is the result of your feedback form. It was submitted by [EMAIL PROTECTED] ([EMAIL PROTECTED]) on Tuesday, January 7, 2003 at 12:57:14 --- g4i: Hey!! What's Up? I'm *Debbie* 20/F/San Diego/Webcam & Pics. I'm *LIVE* on my *FREE* Webcam mostly 24/7 so if you wanna come in and chat or see me go to my Personal Homepage at http://www.freelivecamgirls.net and i'll talk to you in a bit hun! If you join and the webchat is already full im sorry, just wait like 5 minutes and then you'll be able to see me LIVE!! *Remember* this is my Personal Homepage so of course its *FREE* =) <333 *Debbie* <333 PS.Remember my Personal Homepage is http://www.freelivecamgirls.net and hopefully I can chat with you soon!! oh yah!! If you don't have a webcam of your own its ok!! You can still watch and chat with me then!! ok!! ByE!! <333 *Debbie* <333 7k4y ---
Re: [perl #x19800] LOL
At Tue, 07 Jan 2003 18:59:22 GMT, ([EMAIL PROTECTED]) (via RT) wrote: > # New Ticket Created by ([EMAIL PROTECTED]) > # Please include the string: [perl #19800] > # in the subject line of all future correspondence about this issue. > # http://rt.perl.org/rt2/Ticket/Display.html?id=19800 > Smells like spam to me. I've nuked it. X-Spam-Status: No, hits=5.3 required=7.0 tests=BUGGY_CGI,CARRIAGE_RETURNS,FORGED_YAHOO_RCVD,SPAM_PHRASE_02_03,SUPERLONG_LINE version=2.43 If this address starts to get hammered with things getting through the filter, we'll put a human in the loop. -R
[perl #19807] [PATCH] rx.ops doc typos
# New Ticket Created by Jim Radford # Please include the string: [perl #19807] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt2/Ticket/Display.html?id=19807 > I found a few typos while reading through the documentation in rx.ops. -Jim --- parrot-0.0.9/rx.ops.origMon Jan 6 15:28:08 2003 +++ parrot-0.0.9/rx.ops Mon Jan 6 15:38:41 2003 @@ -405,7 +405,7 @@ =item C(in str, inout int, in pmc, inconst int) -Matches if the current character is one of the characters in the second parameter. +Matches if the current character is one of the characters in the third parameter. This op requires that its input be sorted for efficiency. Further, it requires that all ranges (C) be expanded by the regex compiler. @@ -437,7 +437,7 @@ =item C(in str, inout int, in pmc, inconst int) -This op has the exact same behavior as C, except that the second parameter +This op has the exact same behavior as C, except that the third parameter is a Pointer to a bitmap generated by C. =cut @@ -542,10 +542,10 @@ =item C(in str, out int, inout int, in str, inconst in) -Searches for the literal $4 on the string $1. Sets $2 to the current +Searches for the literal $4 on the string $1 starting at $3. Sets $2 to the current index in the string (after the literal), and $3 to start_index. -Branches to $4 if the literal is not found. +Branches to $5 if the literal is not found. =cut @@ -597,10 +597,10 @@ =item C (in str, out int, inout int, in str, inconst in) -Searches for the char $4 on the string $1. Sets $2 to the current +Searches for the char $4 on the string $1 starting at $3. Sets $2 to the current index in the string (after the char) -Branches to $4 if the char is not found. +Branches to $5 if the char is not found. The char is expressed as an integer representing its codepoint. @@ -914,7 +914,7 @@ set I0, 0 $start: - rx_literal, S0, I1, I0, "foobar", $fail + rx_search, S0, I1, I0, "foobar", $fail print "match" branch $end $fail:
Re: [perl #x19800] LOL
On Tue, Jan 07, 2003 at 02:04:25PM -0800, Robert Spier wrote: > At Tue, 07 Jan 2003 18:59:22 GMT, > ([EMAIL PROTECTED]) (via RT) wrote: > > # New Ticket Created by ([EMAIL PROTECTED]) > > # Please include the string: [perl #19800] > > # in the subject line of all future correspondence about this issue. > > # http://rt.perl.org/rt2/Ticket/Display.html?id=19800 > > > > Smells like spam to me. I've nuked it. > > X-Spam-Status: No, hits=5.3 required=7.0 > tests=BUGGY_CGI,CARRIAGE_RETURNS,FORGED_YAHOO_RCVD,SPAM_PHRASE_02_03,SUPERLONG_LINE > version=2.43 There's no test for sent-from-a-formmail script? For a bug report that alone ought to sent it over the spam threshold Nicholas Clark
Re: [perl #19729] [PATCH] SPARC JIT support for restart
Applied, thanks. Daniel Grunblatt. On Sunday 05 January 2003 01:10, Jason Gloudon (via RT) wrote: > # New Ticket Created by Jason Gloudon > # Please include the string: [perl #19729] > # in the subject line of all future correspondence about this issue. > # http://rt.perl.org/rt2/Ticket/Display.html?id=19729 > > > > > This patch adds JIT support for restart and similar ops.
Re: This week's Perl Summary
On Jan-04, Leopold Toetsch wrote: > Damian Conway wrote: > > >Piers Cawley wrote: > > > >>Acknowledgements > > > >But, of course, modesty forebade him from thanking the tireless Perl 6 > >summarizer himself, for his sterling efforts wading through the morasses > >that are P6-language and P6-internals > > Remembering e.g. perl6 operator threads, brrr, I just can say ... > > >Thank-you, Piers! > > me2 Me3. But watch out -- you are single-handedly responsibility for the sanity of hundreds of us, and are therefore responsible for anything we might do in this unnatural state.
