(command.CommandList children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:basedir) op: assign_op.Equal rhs: { (command_sub left_token: <Id.Left_Backtick '`'> child: (C {<dirname>} {($ Id.VSub_Number '$0')}) ) } spids: [21] ) ] ) (C {<source>} {(${ Id.VSub_Name basedir) <'/functions.sh'>}) (C {<root_check_run_with_sudo>} {(DQ ($ Id.VSub_At '$@'))}) (C {<source>} {(${ Id.VSub_Name basedir) <'/parameters.sh'>}) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {<Id.Lit_LBracket '['>} {<-z>} {(DQ ($ Id.VSub_DollarName '$DEST_IP'))} {<Id.Lit_RBracket ']'>} ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:DEST_IP) op: assign_op.Equal rhs: {(DQ <198.18.0.42>)} spids: [69] ) ] ) ] ) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {<Id.Lit_LBracket '['>} {<-z>} {(DQ ($ Id.VSub_DollarName '$DST_MAC'))} {<Id.Lit_RBracket ']'>} ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:DST_MAC) op: assign_op.Equal rhs: {(DQ <'90:e2:ba:ff:ff:ff'>)} spids: [86] ) ] ) ] ) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {<Id.Lit_LBracket '['>} {<-z>} {(DQ ($ Id.VSub_DollarName '$CLONE_SKB'))} {<Id.Lit_RBracket ']'>} ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:CLONE_SKB) op: assign_op.Equal rhs: {(DQ <0>)} spids: [103] ) ] ) ] ) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {<Id.Lit_LBracket '['>} {<-z>} {(DQ ($ Id.VSub_DollarName '$FLOWS'))} {<Id.Lit_RBracket ']'>}) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:FLOWS) op: assign_op.Equal rhs: {(DQ <8000>)} spids: [136] ) ] ) ] ) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {<Id.Lit_LBracket '['>} {<-z>} {(DQ ($ Id.VSub_DollarName '$FLOWLEN'))} {<Id.Lit_RBracket ']'>} ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:FLOWLEN) op: assign_op.Equal rhs: {(DQ <10>)} spids: [153] ) ] ) ] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:DELAY) op: assign_op.Equal rhs: {(DQ <0>)} spids: [162] ) ] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:COUNT) op: assign_op.Equal rhs: {(DQ <0>)} spids: [170] ) ] ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DBracket expr: (bool_expr.Unary op_id: Id.BoolUnary_n child: {(DQ ($ Id.VSub_DollarName '$BURST'))} ) ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<err>} {<1>} {(DQ <'Bursting not supported for this mode'>)})] spids: [179 192] ) ] ) (C {<pg_ctrl>} {(DQ <reset>)}) (command.ForExpr init: (arith_expr.BinaryAssign op_id: Id.Arith_Equal left: <Id.Lit_ArithVarLike thread> right: {<Id.Lit_Digits 0>} ) cond: (arith_expr.Binary op_id: Id.Arith_Less left: <Id.Lit_ArithVarLike thread> right: {($ Id.VSub_DollarName '$THREADS')} ) update: (arith_expr.UnaryAssign op_id:Id.Node_PostDPlus child:<Id.Lit_ArithVarLike thread>) body: (command.DoGroup children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:dev) op: assign_op.Equal rhs: {(${ Id.VSub_Name DEV) <Id.Lit_At '@'> (${ Id.VSub_Name thread)} spids: [245] ) ] ) (C {<pg_thread>} {($ Id.VSub_DollarName '$thread')} {(DQ <rem_device_all>)}) (C {<pg_thread>} {($ Id.VSub_DollarName '$thread')} {(DQ <add_device>)} {($ Id.VSub_DollarName '$dev')} ) (C {<pg_set>} {($ Id.VSub_DollarName '$dev')} {(DQ <'flag QUEUE_MAP_CPU'>)}) (C {<pg_set>} {($ Id.VSub_DollarName '$dev')} {(DQ <'count '> ($ Id.VSub_DollarName '$COUNT'))} ) (C {<pg_set>} {($ Id.VSub_DollarName '$dev')} {(DQ <'clone_skb '> ($ Id.VSub_DollarName '$CLONE_SKB'))} ) (C {<pg_set>} {($ Id.VSub_DollarName '$dev')} {(DQ <'pkt_size '> ($ Id.VSub_DollarName '$PKT_SIZE'))} ) (C {<pg_set>} {($ Id.VSub_DollarName '$dev')} {(DQ <'delay '> ($ Id.VSub_DollarName '$DELAY'))} ) (C {<pg_set>} {($ Id.VSub_DollarName '$dev')} {(DQ <'flag NO_TIMESTAMP'>)}) (C {<pg_set>} {($ Id.VSub_DollarName '$dev')} {(DQ <'dst_mac '> ($ Id.VSub_DollarName '$DST_MAC'))} ) (C {<pg_set>} {($ Id.VSub_DollarName '$dev')} {(DQ <'dst '> ($ Id.VSub_DollarName '$DEST_IP'))} ) (C {<pg_set>} {($ Id.VSub_DollarName '$dev')} {(DQ <'flag IPSRC_RND'>)}) (C {<pg_set>} {($ Id.VSub_DollarName '$dev')} {(DQ <'src_min 198.18.0.0'>)}) (C {<pg_set>} {($ Id.VSub_DollarName '$dev')} {(DQ <'src_max 198.19.255.255'>)}) (C {<pg_set>} {($ Id.VSub_DollarName '$dev')} {(DQ <'flows '> ($ Id.VSub_DollarName '$FLOWS'))} ) (C {<pg_set>} {($ Id.VSub_DollarName '$dev')} {(DQ <'flowlen '> ($ Id.VSub_DollarName '$FLOWLEN'))} ) (C {<pg_set>} {($ Id.VSub_DollarName '$dev')} {(DQ <'flag FLOW_SEQ'>)}) ] ) ) (command.ShFunction name: print_result body: (BraceGroup children: [ (command.ForExpr init: (arith_expr.BinaryAssign op_id: Id.Arith_Equal left: <Id.Lit_ArithVarLike thread> right: {<Id.Lit_Digits 0>} ) cond: (arith_expr.Binary op_id: Id.Arith_Less left: <Id.Lit_ArithVarLike thread> right: {($ Id.VSub_DollarName '$THREADS')} ) update: (arith_expr.UnaryAssign op_id: Id.Node_PostDPlus child: <Id.Lit_ArithVarLike thread> ) body: (command.DoGroup children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:dev) op: assign_op.Equal rhs: {(${ Id.VSub_Name DEV) <Id.Lit_At '@'> (${ Id.VSub_Name thread)} spids: [511] ) ] ) (C {<echo>} {(DQ <'Device: '> ($ Id.VSub_DollarName '$dev'))}) (command.Pipeline children: [ (C {<cat>} {<'/proc/net/pktgen/'> ($ Id.VSub_DollarName '$dev')}) (C {<grep>} {<-A2>} {(DQ <'Result:'>)}) ] negated: F ) ] ) ) ] ) ) (C {<trap>} {<true>} {<SIGINT>}) (command.Simple words: [{<echo>} {(DQ <'Running... ctrl^C to stop'>)}] redirects: [(redir op:<Id.Redir_GreatAnd '>&'> loc:(redir_loc.Fd fd:1) arg:{<2>})] do_fork: T ) (C {<pg_ctrl>} {(DQ <start>)}) (C {<print_result>}) ] )