(command.CommandList
  children: [
    (C {<set>} {<-o>} {<pipefail>})
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (C {<Id.Lit_LBracket '['>} {($ Id.VSub_Pound '$#')} {<-lt>} {<4>} {<Id.Lit_RBracket ']'>})
              ]
            )
          action: [
            (command.Simple
              words: [{<echo>} {(DQ <'usage: bisectinate ARCH PACKAGE REPO[@BAD] GOOD [TEST...]'>)}]
              redirects: [(redir op:<Id.Redir_GreatAnd '>&'> loc:(redir_loc.Fd fd:1) arg:{<2>})]
              do_fork: T
            )
            (command.Simple
              words: [{<echo>}]
              redirects: [(redir op:<Id.Redir_GreatAnd '>&'> loc:(redir_loc.Fd fd:1) arg:{<2>})]
              do_fork: T
            )
            (command.Simple
              words: [{<echo>} {(DQ <'Bisect PACKAGE for ARCH, from START to BAD within REPO'>)}]
              redirects: [(redir op:<Id.Redir_GreatAnd '>&'> loc:(redir_loc.Fd fd:1) arg:{<2>})]
              do_fork: T
            )
            (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<1>})
          ]
          spids: [22 34]
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:ARCH)
          op: assign_op.Equal
          rhs: {(DQ ($ Id.VSub_Number '$1'))}
          spids: [74]
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:PKG)
          op: assign_op.Equal
          rhs: {(DQ ($ Id.VSub_Number '$2'))}
          spids: [79]
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:REPO)
          op: assign_op.Equal
          rhs: 
            {
              (DQ 
                (braced_var_sub
                  token: <Id.VSub_Number 3>
                  suffix_op: 
                    (suffix_op.PatSub
                      pat: {<Id.Lit_Other '@'> <Id.Lit_Other '*'>}
                      replace: {}
                      replace_mode: Id.Undefined_Tok
                    )
                )
              )
            }
          spids: [84]
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:BRANCH)
          op: assign_op.Equal
          rhs: 
            {
              (DQ 
                (braced_var_sub
                  token: <Id.VSub_Number 3>
                  suffix_op: 
                    (suffix_op.PatSub
                      pat: {<Id.Lit_Other '*'> <Id.Lit_Other '@'>}
                      replace: {}
                      replace_mode: Id.Undefined_Tok
                    )
                )
              )
            }
          spids: [95]
        )
      ]
    )
    (command.AndOr
      ops: [Id.Op_DAmp]
      children: [
        (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$BRANCH'))} 
          {<Id.Lit_Equals '='> <Id.Lit_Equals '='>} {(DQ ($ Id.VSub_Number '$3'))} {<Id.Lit_RBracket ']'>}
        )
        (command.ShAssignment
          pairs: [
            (assign_pair
              lhs: (sh_lhs_expr.Name name:BRANCH)
              op: assign_op.Equal
              rhs: {<master>}
              spids: [123]
            )
          ]
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:START)
          op: assign_op.Equal
          rhs: {(DQ ($ Id.VSub_Number '$4'))}
          spids: [126]
        )
      ]
    )
    (C {<shift>} {<4>})
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:TEST)
          op: assign_op.Equal
          rhs: {(DQ ($ Id.VSub_Number '$1'))}
          spids: [135]
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:TOP)
          op: assign_op.Equal
          rhs: {(DQ (command_sub left_token:<Id.Left_DollarParen '$('> child:(C {<pwd>})))}
          spids: [141]
        )
      ]
    )
    (command.AndOr
      ops: [Id.Op_DAmp]
      children: [
        (C {<Id.Lit_LBracket '['>} {<-z>} {(DQ ($ Id.VSub_DollarName '$SRCDIR'))} {<Id.Lit_RBracket ']'>})
        (command.ShAssignment
          pairs: [
            (assign_pair
              lhs: (sh_lhs_expr.Name name:SRCDIR)
              op: assign_op.Equal
              rhs: {(DQ ($ Id.VSub_DollarName '$TOP') <'/packages'>)}
              spids: [160]
            )
          ]
        )
      ]
    )
    (command.AndOr
      ops: [Id.Op_DAmp]
      children: [
        (C {<Id.Lit_LBracket '['>} {<-z>} {(DQ ($ Id.VSub_DollarName '$BUILD'))} {<Id.Lit_RBracket ']'>})
        (command.ShAssignment
          pairs: [
            (assign_pair
              lhs: (sh_lhs_expr.Name name:BUILD)
              op: assign_op.Equal
              rhs: {(DQ ($ Id.VSub_DollarName '$TOP') <'/build'>)}
              spids: [178]
            )
          ]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (C {<Id.Lit_LBracket '['>} {<Id.KW_Bang '!'>} {<-d>} 
                  {(DQ ($ Id.VSub_DollarName '$REPO') <'/.git'>)} {<Id.Lit_RBracket ']'>}
                )
              ]
            )
          action: [
            (C {<echo>} {(DQ <'No git repo at '> ($ Id.VSub_DollarName '$REPO'))})
            (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<1>})
          ]
          spids: [185 200]
        )
      ]
    )
    (command.AndOr
      ops: [Id.Op_DAmp]
      children: [
        (C {<Id.Lit_LBracket '['>} {<-z>} {(DQ ($ Id.VSub_DollarName '$TEST'))} {<Id.Lit_RBracket ']'>})
        (command.ShAssignment
          pairs: [
            (assign_pair
              lhs: (sh_lhs_expr.Name name:TEST)
              op: assign_op.Equal
              rhs: {<true>}
              spids: [230]
            )
          ]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.AndOr
                  ops: [Id.Op_DAmp]
                  children: [
                    (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$PKG'))} 
                      {<Id.Lit_Equals '='> <Id.Lit_Equals '='>} {<linux>} {<Id.Lit_RBracket ']'>}
                    )
                    (C {<Id.Lit_LBracket '['>} {<-e>} 
                      {
                        (DQ ($ Id.VSub_DollarName '$BUILD') <'/root-filesystem-'> 
                          ($ Id.VSub_DollarName '$ARCH')
                        ) <.tar.bz2>
                      } {<Id.Lit_RBracket ']'>}
                    )
                  ]
                )
              ]
            )
          action: [
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:ZAPJUST)
                  op: assign_op.Equal
                  rhs: {<linux-kernel>}
                  spids: [271]
                )
              ]
            )
          ]
          spids: [238 268]
        )
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.AndOr
                  ops: [Id.Op_DAmp]
                  children: [
                    (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName '$PKG'))} 
                      {<Id.Lit_Equals '='> <Id.Lit_Equals '='>} {<busybox>} {<Id.Lit_RBracket ']'>}
                    )
                    (C {<Id.Lit_LBracket '['>} {<-e>} 
                      {
                        (DQ ($ Id.VSub_DollarName '$BUILD') <'/simple-cross-compiler-'> 
                          ($ Id.VSub_DollarName '$ARCH') <.tar.bz2>
                        )
                      } {<Id.Lit_RBracket ']'>}
                    )
                  ]
                )
              ]
            )
          action: [
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:ZAPJUST)
                  op: assign_op.Equal
                  rhs: {<root-filesystem>}
                  spids: [308]
                )
              ]
            )
          ]
          spids: [274 305]
        )
      ]
      else_action: [
        (command.ShAssignment
          pairs: [
            (assign_pair
              lhs: (sh_lhs_expr.Name name:ZAPJUST)
              op: assign_op.Equal
              rhs: (word.Empty)
              spids: [314]
            )
          ]
        )
      ]
    )
    (command.AndOr
      ops: [Id.Op_DAmp Id.Op_DAmp Id.Op_DAmp Id.Op_DAmp Id.Op_DAmp Id.Op_DAmp Id.Op_DPipe]
      children: [
        (C {<rm>} {<-rf>} 
          {(DQ ($ Id.VSub_DollarName '$BUILD') <'/packages/alt-'> ($ Id.VSub_DollarName '$PKG'))} {(DQ ($ Id.VSub_DollarName '$SRCDIR') <'/alt-'> ($ Id.VSub_DollarName '$PKG') <-0.tar.bz2>)}
        )
        (C {<mkdir>} {<-p>} 
          (word.BracedTree
            parts: [
              (DQ ($ Id.VSub_DollarName '$BUILD'))
              <'/'>
              (word_part.BracedTuple words:[{<logs>} {<packages>}])
            ]
          )
        )
        (C {<cd>} {(DQ ($ Id.VSub_DollarName '$BUILD') <'/packages'>)})
        (C {<git>} {<clone>} {(DQ ($ Id.VSub_DollarName '$REPO'))} 
          {(DQ <alt-> ($ Id.VSub_DollarName '$PKG'))}
        )
        (C {<cd>} {(DQ <alt-> ($ Id.VSub_DollarName '$PKG'))})
        (C {<git>} {<bisect>} {<start>})
        (C {<git>} {<bisect>} {<good>} {(DQ ($ Id.VSub_DollarName '$START'))})
        (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<1>})
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:RESULT)
          op: assign_op.Equal
          rhs: {(DQ <'bad '> ($ Id.VSub_DollarName '$BRANCH'))}
          spids: [416]
        )
      ]
    )
    (command.WhileUntil
      keyword: <Id.KW_While while>
      cond: (condition.Shell commands:[(C {<true>})])
      body: 
        (command.DoGroup
          children: [
            (command.AndOr
              ops: [Id.Op_DAmp Id.Op_DAmp Id.Op_DPipe]
              children: [
                (C {<cd>} 
                  {
                    (DQ ($ Id.VSub_DollarName '$BUILD') <'/packages/alt-'> 
                      ($ Id.VSub_DollarName '$PKG')
                    )
                  }
                )
                (C {<git>} {<clean>} {<-fdx>})
                (C {<git>} {<checkout>} {<-f>})
                (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<1>})
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:RESULT)
                  op: assign_op.Equal
                  rhs: 
                    {
                      (DQ 
                        (command_sub
                          left_token: <Id.Left_DollarParen '$('>
                          child: (C {<git>} {<bisect>} {($ Id.VSub_DollarName '$RESULT')})
                        )
                      )
                    }
                  spids: [473]
                )
              ]
            )
            (C {<echo>} {(DQ ($ Id.VSub_DollarName '$RESULT'))})
            (command.AndOr
              ops: [Id.Op_DAmp]
              children: [
                (C {<Id.Lit_LBracket '['>} {<Id.KW_Bang '!'>} 
                  {
                    (DQ 
                      (command_sub
                        left_token: <Id.Left_DollarParen '$('>
                        child: 
                          (command.Pipeline
                            children: [
                              (C {<echo>} {(DQ ($ Id.VSub_DollarName '$RESULT'))})
                              (C {<head>} {<-n>} {<1>})
                              (C {<grep>} {(DQ <'^Bisecting:'>)})
                            ]
                            negated: F
                          )
                      )
                    )
                  } {<Id.Lit_RBracket ']'>}
                )
                (command.ControlFlow token:<Id.ControlFlow_Exit exit>)
              ]
            )
            (command.Simple
              words: [{<git>} {<show>}]
              redirects: [
                (redir
                  op: <Id.Redir_Great '>'>
                  loc: (redir_loc.Fd fd:1)
                  arg: 
                    {
                      (DQ ($ Id.VSub_DollarName '$BUILD') <'/logs/bisectinate-'> (${ Id.VSub_Name ARCH) 
                        <.txt>
                      )
                    }
                )
              ]
              do_fork: T
            )
            (command.Simple
              words: [{<git>} {<bisect>} {<log>}]
              redirects: [
                (redir
                  op: <Id.Redir_Great '>'>
                  loc: (redir_loc.Fd fd:1)
                  arg: 
                    {
                      (DQ ($ Id.VSub_DollarName '$BUILD') <'/logs/bisectinate-'> (${ Id.VSub_Name ARCH) 
                        <.log>
                      )
                    }
                )
              ]
              do_fork: T
            )
            (command.Pipeline
              children: [(C {<git>} {<log>} {<HEAD>} {<-1>}) (C {<cat>})]
              negated: F
            )
            (C {<echo>} {(DQ <Testing...>)})
            (command.AndOr
              ops: [Id.Op_DPipe]
              children: [
                (C {<cd>} {(DQ ($ Id.VSub_DollarName '$TOP'))})
                (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<1>})
              ]
            )
            (command.AndOr
              ops: [Id.Op_DAmp Id.Op_DPipe]
              children: [
                (C {<Id.Lit_LBracket '['>} {<Id.KW_Bang '!'>} {<-z>} 
                  {(DQ ($ Id.VSub_DollarName '$ZAPJUST'))} {<Id.Lit_RBracket ']'>}
                )
                (C {<rm>} {<-rf>} 
                  (word.BracedTree
                    parts: [
                      (DQ ($ Id.VSub_DollarName '$BUILD') <'/'> (${ Id.VSub_Name ZAPJUST) <-> 
                        ($ Id.VSub_DollarName '$ARCH')
                      )
                      (word_part.BracedTuple words:[{} {<.tar.bz2>}])
                    ]
                  )
                )
                (C {<rm>} {<-rf>} 
                  (word.BracedTree
                    parts: [
                      (DQ ($ Id.VSub_DollarName '$BUILD'))
                      <'/'>
                      <Id.Lit_Star '*'>
                      <->
                      (DQ ($ Id.VSub_DollarName '$ARCH'))
                      (word_part.BracedTuple words:[{} {<.tar.bz2>}])
                    ]
                  )
                )
              ]
            )
            (command.Pipeline
              children: [
                (command.Simple
                  words: [{<'./build.sh'>} {(DQ ($ Id.VSub_DollarName '$ARCH'))}]
                  redirects: [(redir op:<Id.Redir_GreatAnd '2>&'> loc:(redir_loc.Fd fd:2) arg:{<1>})]
                  more_env: [
                    (env_pair name:EXTRACT_ALL val:{<1>} spids:[674])
                    (env_pair name:ALLOW_PATCH_FAILURE val:{<1>} spids:[677])
                    (env_pair
                      name: USE_ALT
                      val: {(DQ ($ Id.VSub_DollarName '$PKG'))}
                      spids: [680]
                    )
                  ]
                  do_fork: T
                )
                (C {<tee>} {<-a>} 
                  {(DQ ($ Id.VSub_DollarName '$BUILD')) <'/logs/bisectinate-'> 
                    (DQ ($ Id.VSub_DollarName '$ARCH')) <.txt>
                  }
                )
              ]
              negated: F
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:RESULT)
                  op: assign_op.Equal
                  rhs: {<bad>}
                  spids: [718]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (C {<Id.Lit_LBracket '['>} {<-e>} 
                          {(DQ ($ Id.VSub_DollarName '$BUILD')) <'/system-image-'> 
                            (DQ ($ Id.VSub_DollarName '$ARCH')) <.tar.bz2>
                          } {<Id.Lit_RBracket ']'>}
                        )
                      ]
                    )
                  action: [
                    (C {<set>} {<-o>} {<pipefail>})
                    (command.Pipeline
                      children: [
                        (command.Simple
                          words: [{<'more/timeout.sh'>} {<60>} {(DQ ($ Id.VSub_DollarName '$TEST'))}]
                          redirects: [
                            (redir
                              op: <Id.Redir_GreatAnd '2>&'>
                              loc: (redir_loc.Fd fd:2)
                              arg: {<1>}
                            )
                          ]
                          more_env: [
                            (env_pair
                              name: ARCH
                              val: {(DQ ($ Id.VSub_DollarName '$ARCH'))}
                              spids: [750]
                            )
                          ]
                          do_fork: T
                        )
                        (C {<tee>} {<-a>} 
                          {
                            (DQ ($ Id.VSub_DollarName '$BUILD') <'/logs/bisectinate-'> 
                              ($ Id.VSub_DollarName '$ARCH')
                            ) <.txt>
                          }
                        )
                      ]
                      negated: F
                    )
                    (command.AndOr
                      ops: [Id.Op_DAmp]
                      children: [
                        (C {<Id.Lit_LBracket '['>} {($ Id.VSub_QMark '$?')} {<-eq>} {<0>} 
                          {<Id.Lit_RBracket ']'>}
                        )
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:RESULT)
                              op: assign_op.Equal
                              rhs: {<good>}
                              spids: [794]
                            )
                          ]
                        )
                      ]
                    )
                  ]
                  spids: [722 740]
                )
              ]
            )
            (C {<mv>} 
              (word.BracedTree
                parts: [
                  (DQ ($ Id.VSub_DollarName '$BUILD'))
                  <'/logs/bisectinate'>
                  (word_part.BracedTuple
                    words: [{} {<-> ($ Id.VSub_DollarName '$RESULT')}]
                  )
                  <->
                  (DQ ($ Id.VSub_DollarName '$ARCH'))
                  <.txt>
                ]
              )
            )
          ]
        )
    )
  ]
)