[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: performance bug of [[ $x ]]

From: Peng Yu
Subject: Re: performance bug of [[ $x ]]
Date: Sat, 7 Mar 2020 18:33:19 -0600

Could you show me how you do the profiling for this specific case?
Based on what proof that you can conclude that it is not the `[[`
performance problem?

On 3/7/20, Chris Down <address@hidden> wrote:
> Peng Yu writes:
>>[[ $x ]] just tests whether the variable $x is of length 0 or not. So
>>its performance should not depend on how long the variable is.
> Who said it has anything to do with the [[ builtin's performance? A shell
> does
> a lot more than just running one command.
> For this and the last issue you posted, you could quite trivially find out
> the
> answer yourself using `perf` or another profiler.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]