TL;DR: It appears chained evals are slightly faster than separated evals.
Methodology:
We are able to go through this ourselves using the job inspector.
Following is a run anywhere example scaled up and ran in verbose mode, so differences might be seen.
The gentimes command is used to generate unique timestamps at 1 second for each event, so we get unique events every time we run the search. In the command below, it generates 8,640,000 events (which is the number of seconds in 100 days).
Chained Command:
| gentimes start=-100 end=0 increment=1s
| eval A = "OM" , B = "NOM" , C = "NOM" , D = "NOM" , E = "NOM" , F = "OM" , G = "NOM" , H = "NOM" , I = "NOM" , J = "NOM" , K = "OM" , L = "NOM" , M = "NOM" , N = "NOM" , O = "NOM" , P = "OM" , Q = "NOM" , R = "NOM" , S = "NOM" , T = "NOM" , U = "OM" , V = "NOM" , W = "NOM" , X = "NOM" , Y = "NOM" , Z = "OM"
Separated Command:
| gentimes start=-100 end=0 increment=1s
| eval A = "OM"
| eval B = "NOM"
| eval C = "NOM"
| eval D = "NOM"
| eval E = "NOM"
| eval F = "OM"
| eval G = "NOM"
| eval H = "NOM"
| eval I = "NOM"
| eval J = "NOM"
| eval K = "OM"
| eval L = "NOM"
| eval M = "NOM"
| eval N = "NOM"
| eval O = "NOM"
| eval P = "OM"
| eval Q = "NOM"
| eval R = "NOM"
| eval S = "NOM"
| eval T = "NOM"
| eval U = "OM"
| eval V = "NOM"
| eval W = "NOM"
| eval X = "NOM"
| eval Y = "NOM"
| eval Z = "OM"
Results:
of Events = 8,640,000
Chained Evals Search Time = 325.429 (80.13 seconds for the command.eval)
Separated Evals Search Time = 348.053 (98.77 seconds for the command.eval)
I seem to recall, but was not able to locate a reference, that every pipe costs something. In this example of 8.64 million events, that looks to be at least 18 seconds more using separated evals than chained evals (the remaining time is between running command.gentimes). YMMV based on your needs and your infrastructure, but it might be worth the readability to use the extra text and separate the evals.
... View more