From mboxrd@z Thu Jan 1 00:00:00 1970 From: Peter Feiner Subject: Re: [PATCH kvm-unit-tests v7 5/5] scripts: automatically pretty print stacks Date: Thu, 31 Mar 2016 16:33:17 -0700 Message-ID: <20160331233317.GA31870@google.com> References: <56FA635A.5000307@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: drjones@redhat.com, kvm@vger.kernel.org To: Paolo Bonzini Return-path: Received: from mail-pf0-f181.google.com ([209.85.192.181]:33502 "EHLO mail-pf0-f181.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754687AbcCaXdT (ORCPT ); Thu, 31 Mar 2016 19:33:19 -0400 Received: by mail-pf0-f181.google.com with SMTP id 4so80104472pfd.0 for ; Thu, 31 Mar 2016 16:33:19 -0700 (PDT) Content-Disposition: inline In-Reply-To: <56FA635A.5000307@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On Tue, Mar 29, 2016 at 01:13:30PM +0200, Paolo Bonzini wrote: > > > On 23/03/2016 00:35, Peter Feiner wrote: > > +if [ "$PRETTY_PRINT_STACKS" = "yes" ]; then > > + log_redir="> >(./scripts/pretty_print_stacks.py \$kernel >> test.log)" > > Isn't this the same as "| ./scripts/pretty_print_stack.py \$kernel >> > test.log"? Not the same. Consider scripts/runtime.bash's usage: cmdline="...$RUNTIME_arch_run $kernel -smp $smp $opts" With your alternative, the command-line arguments after $RUNTIME_arch_run are be passed to pretty_print_stacks.py instead of Qemu. > If so, perhaps > > if [ "$PRETTY_PRINT_STACKS" = "yes" ]; then > stack_filter="./scripts/pretty_print_stack.py \$kernel" > else > stack_filter=cat > > RUNTIME_arch_run="./$TEST_DIR/run | $stack_filter >> test.log" > > ... would be a bit easier to read. Yes, it's super ugly, but it works! Peter