From 72ca7220f21ef32f17d12cfde1bd9732d56fb872 Mon Sep 17 00:00:00 2001 From: Mike Hommey Date: Mon, 16 Apr 2012 16:30:23 +0200 Subject: [PATCH] Use echo instead of cat in loops in size_classes.sh This avoids fork/exec()ing in loops, as echo is a builtin, and makes size_classes.sh much faster (from > 10s to < 0.2s on mingw on my machine). --- include/jemalloc/internal/size_classes.sh | 32 ++++++++--------------- 1 file changed, 11 insertions(+), 21 deletions(-) diff --git a/include/jemalloc/internal/size_classes.sh b/include/jemalloc/internal/size_classes.sh index 3d236136..29c80c1f 100755 --- a/include/jemalloc/internal/size_classes.sh +++ b/include/jemalloc/internal/size_classes.sh @@ -35,10 +35,8 @@ while [ ${lg_q} -le ${lg_qmax} ] ; do while [ ${lg_t} -le ${lg_q} ] ; do lg_p=${lg_pmin} while [ ${lg_p} -le ${lg_pmax} ] ; do - cat <