[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] Improve memory management in join
From: |
Jim Meyering |
Subject: |
Re: [PATCH] Improve memory management in join |
Date: |
Tue, 17 Jun 2008 00:56:21 +0200 |
"Bo Borgerson" <address@hidden> wrote:
> This improves the performance of `join' by reducing memory management
> overhead and eliminating unnecessary copies for order checking:
>
> $ valgrind src/join.master ja jb
> ==23744== malloc/free: 4,571,152 allocs, 4,571,152 frees, 255,971,774
> bytes allocated.
>
> $ valgrind src/join ja jb
> ==23738== malloc/free: 1,405 allocs, 1,405 frees, 65,858 bytes allocated.
>
> $ time src/join.master ja jb
> user 0m27.126s
>
> $ time src/join ja jb
> user 0m17.297s
Thanks again.
I've pushed that patch.
I didn't come up with any easy/portable way to
test for the improvement. I could run valgrind to
count malloc calls, with appropriate restrictions
to ensure valgrind will work, but that's not easy.
Suggestions welcome.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [PATCH] Improve memory management in join,
Jim Meyering <=