Training courses

Kernel and Embedded Linux

Bootlin training courses

Embedded Linux, kernel,
Yocto Project, Buildroot, real-time,
graphics, boot time, debugging...

Bootlin logo

Elixir Cross Referencer

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
   0  $accept : list $end

   1  list :
   2       | list stat '\n'
   3       | list error '\n'

   4  stat : expr
   5       | LETTER '=' expr

   6  expr : '(' expr ')'
   7       | expr "ADD" expr
   8       | expr "SUB" expr
   9       | expr "MUL" expr
  10       | expr "DIV" expr
  11       | expr "MOD" expr
  12       | expr "AND" expr
  13       | expr '|' expr
  14       | "SUB" expr
  15       | LETTER
  16       | number

  17  number : DIGIT
  18         | number DIGIT

state 0
	$accept : . list $end  (0)
	list : .  (1)

	.  reduce 1

	list  goto 1


state 1
	$accept : list . $end  (0)
	list : list . stat '\n'  (2)
	list : list . error '\n'  (3)

	$end  accept
	error  shift 2
	"SUB"  shift 3
	DIGIT  shift 4
	LETTER  shift 5
	'('  shift 6
	.  error

	stat  goto 7
	expr  goto 8
	number  goto 9


state 2
	list : list error . '\n'  (3)

	'\n'  shift 10
	.  error


state 3
	expr : "SUB" . expr  (14)

	"SUB"  shift 3
	DIGIT  shift 4
	LETTER  shift 11
	'('  shift 6
	.  error

	expr  goto 12
	number  goto 9


state 4
	number : DIGIT .  (17)

	.  reduce 17


state 5
	stat : LETTER . '=' expr  (5)
	expr : LETTER .  (15)

	'='  shift 13
	"ADD"  reduce 15
	"SUB"  reduce 15
	"MUL"  reduce 15
	"DIV"  reduce 15
	"MOD"  reduce 15
	"AND"  reduce 15
	'|'  reduce 15
	'\n'  reduce 15


state 6
	expr : '(' . expr ')'  (6)

	"SUB"  shift 3
	DIGIT  shift 4
	LETTER  shift 11
	'('  shift 6
	.  error

	expr  goto 14
	number  goto 9


state 7
	list : list stat . '\n'  (2)

	'\n'  shift 15
	.  error


state 8
	stat : expr .  (4)
	expr : expr . "ADD" expr  (7)
	expr : expr . "SUB" expr  (8)
	expr : expr . "MUL" expr  (9)
	expr : expr . "DIV" expr  (10)
	expr : expr . "MOD" expr  (11)
	expr : expr . "AND" expr  (12)
	expr : expr . '|' expr  (13)

	"ADD"  shift 16
	"SUB"  shift 17
	"MUL"  shift 18
	"DIV"  shift 19
	"MOD"  shift 20
	"AND"  shift 21
	'|'  shift 22
	'\n'  reduce 4


state 9
	expr : number .  (16)
	number : number . DIGIT  (18)

	DIGIT  shift 23
	"ADD"  reduce 16
	"SUB"  reduce 16
	"MUL"  reduce 16
	"DIV"  reduce 16
	"MOD"  reduce 16
	"AND"  reduce 16
	'|'  reduce 16
	'\n'  reduce 16
	')'  reduce 16


state 10
	list : list error '\n' .  (3)

	.  reduce 3


state 11
	expr : LETTER .  (15)

	.  reduce 15


12: shift/reduce conflict (shift 16, reduce 14) on "ADD"
12: shift/reduce conflict (shift 17, reduce 14) on "SUB"
12: shift/reduce conflict (shift 18, reduce 14) on "MUL"
12: shift/reduce conflict (shift 19, reduce 14) on "DIV"
12: shift/reduce conflict (shift 20, reduce 14) on "MOD"
12: shift/reduce conflict (shift 21, reduce 14) on "AND"
state 12
	expr : expr . "ADD" expr  (7)
	expr : expr . "SUB" expr  (8)
	expr : expr . "MUL" expr  (9)
	expr : expr . "DIV" expr  (10)
	expr : expr . "MOD" expr  (11)
	expr : expr . "AND" expr  (12)
	expr : expr . '|' expr  (13)
	expr : "SUB" expr .  (14)

	"ADD"  shift 16
	"SUB"  shift 17
	"MUL"  shift 18
	"DIV"  shift 19
	"MOD"  shift 20
	"AND"  shift 21
	'|'  reduce 14
	'\n'  reduce 14
	')'  reduce 14


state 13
	stat : LETTER '=' . expr  (5)

	"SUB"  shift 3
	DIGIT  shift 4
	LETTER  shift 11
	'('  shift 6
	.  error

	expr  goto 24
	number  goto 9


state 14
	expr : '(' expr . ')'  (6)
	expr : expr . "ADD" expr  (7)
	expr : expr . "SUB" expr  (8)
	expr : expr . "MUL" expr  (9)
	expr : expr . "DIV" expr  (10)
	expr : expr . "MOD" expr  (11)
	expr : expr . "AND" expr  (12)
	expr : expr . '|' expr  (13)

	"ADD"  shift 16
	"SUB"  shift 17
	"MUL"  shift 18
	"DIV"  shift 19
	"MOD"  shift 20
	"AND"  shift 21
	'|'  shift 22
	')'  shift 25
	.  error


state 15
	list : list stat '\n' .  (2)

	.  reduce 2


state 16
	expr : expr "ADD" . expr  (7)

	"SUB"  shift 3
	DIGIT  shift 4
	LETTER  shift 11
	'('  shift 6
	.  error

	expr  goto 26
	number  goto 9


state 17
	expr : expr "SUB" . expr  (8)

	"SUB"  shift 3
	DIGIT  shift 4
	LETTER  shift 11
	'('  shift 6
	.  error

	expr  goto 27
	number  goto 9


state 18
	expr : expr "MUL" . expr  (9)

	"SUB"  shift 3
	DIGIT  shift 4
	LETTER  shift 11
	'('  shift 6
	.  error

	expr  goto 28
	number  goto 9


state 19
	expr : expr "DIV" . expr  (10)

	"SUB"  shift 3
	DIGIT  shift 4
	LETTER  shift 11
	'('  shift 6
	.  error

	expr  goto 29
	number  goto 9


state 20
	expr : expr "MOD" . expr  (11)

	"SUB"  shift 3
	DIGIT  shift 4
	LETTER  shift 11
	'('  shift 6
	.  error

	expr  goto 30
	number  goto 9


state 21
	expr : expr "AND" . expr  (12)

	"SUB"  shift 3
	DIGIT  shift 4
	LETTER  shift 11
	'('  shift 6
	.  error

	expr  goto 31
	number  goto 9


state 22
	expr : expr '|' . expr  (13)

	"SUB"  shift 3
	DIGIT  shift 4
	LETTER  shift 11
	'('  shift 6
	.  error

	expr  goto 32
	number  goto 9


state 23
	number : number DIGIT .  (18)

	.  reduce 18


state 24
	stat : LETTER '=' expr .  (5)
	expr : expr . "ADD" expr  (7)
	expr : expr . "SUB" expr  (8)
	expr : expr . "MUL" expr  (9)
	expr : expr . "DIV" expr  (10)
	expr : expr . "MOD" expr  (11)
	expr : expr . "AND" expr  (12)
	expr : expr . '|' expr  (13)

	"ADD"  shift 16
	"SUB"  shift 17
	"MUL"  shift 18
	"DIV"  shift 19
	"MOD"  shift 20
	"AND"  shift 21
	'|'  shift 22
	'\n'  reduce 5


state 25
	expr : '(' expr ')' .  (6)

	.  reduce 6


26: shift/reduce conflict (shift 16, reduce 7) on "ADD"
26: shift/reduce conflict (shift 17, reduce 7) on "SUB"
26: shift/reduce conflict (shift 18, reduce 7) on "MUL"
26: shift/reduce conflict (shift 19, reduce 7) on "DIV"
26: shift/reduce conflict (shift 20, reduce 7) on "MOD"
26: shift/reduce conflict (shift 21, reduce 7) on "AND"
26: shift/reduce conflict (shift 22, reduce 7) on '|'
state 26
	expr : expr . "ADD" expr  (7)
	expr : expr "ADD" expr .  (7)
	expr : expr . "SUB" expr  (8)
	expr : expr . "MUL" expr  (9)
	expr : expr . "DIV" expr  (10)
	expr : expr . "MOD" expr  (11)
	expr : expr . "AND" expr  (12)
	expr : expr . '|' expr  (13)

	"ADD"  shift 16
	"SUB"  shift 17
	"MUL"  shift 18
	"DIV"  shift 19
	"MOD"  shift 20
	"AND"  shift 21
	'|'  shift 22
	'\n'  reduce 7
	')'  reduce 7


27: shift/reduce conflict (shift 16, reduce 8) on "ADD"
27: shift/reduce conflict (shift 17, reduce 8) on "SUB"
27: shift/reduce conflict (shift 18, reduce 8) on "MUL"
27: shift/reduce conflict (shift 19, reduce 8) on "DIV"
27: shift/reduce conflict (shift 20, reduce 8) on "MOD"
27: shift/reduce conflict (shift 21, reduce 8) on "AND"
27: shift/reduce conflict (shift 22, reduce 8) on '|'
state 27
	expr : expr . "ADD" expr  (7)
	expr : expr . "SUB" expr  (8)
	expr : expr "SUB" expr .  (8)
	expr : expr . "MUL" expr  (9)
	expr : expr . "DIV" expr  (10)
	expr : expr . "MOD" expr  (11)
	expr : expr . "AND" expr  (12)
	expr : expr . '|' expr  (13)

	"ADD"  shift 16
	"SUB"  shift 17
	"MUL"  shift 18
	"DIV"  shift 19
	"MOD"  shift 20
	"AND"  shift 21
	'|'  shift 22
	'\n'  reduce 8
	')'  reduce 8


28: shift/reduce conflict (shift 16, reduce 9) on "ADD"
28: shift/reduce conflict (shift 17, reduce 9) on "SUB"
28: shift/reduce conflict (shift 18, reduce 9) on "MUL"
28: shift/reduce conflict (shift 19, reduce 9) on "DIV"
28: shift/reduce conflict (shift 20, reduce 9) on "MOD"
28: shift/reduce conflict (shift 21, reduce 9) on "AND"
28: shift/reduce conflict (shift 22, reduce 9) on '|'
state 28
	expr : expr . "ADD" expr  (7)
	expr : expr . "SUB" expr  (8)
	expr : expr . "MUL" expr  (9)
	expr : expr "MUL" expr .  (9)
	expr : expr . "DIV" expr  (10)
	expr : expr . "MOD" expr  (11)
	expr : expr . "AND" expr  (12)
	expr : expr . '|' expr  (13)

	"ADD"  shift 16
	"SUB"  shift 17
	"MUL"  shift 18
	"DIV"  shift 19
	"MOD"  shift 20
	"AND"  shift 21
	'|'  shift 22
	'\n'  reduce 9
	')'  reduce 9


29: shift/reduce conflict (shift 16, reduce 10) on "ADD"
29: shift/reduce conflict (shift 17, reduce 10) on "SUB"
29: shift/reduce conflict (shift 18, reduce 10) on "MUL"
29: shift/reduce conflict (shift 19, reduce 10) on "DIV"
29: shift/reduce conflict (shift 20, reduce 10) on "MOD"
29: shift/reduce conflict (shift 21, reduce 10) on "AND"
29: shift/reduce conflict (shift 22, reduce 10) on '|'
state 29
	expr : expr . "ADD" expr  (7)
	expr : expr . "SUB" expr  (8)
	expr : expr . "MUL" expr  (9)
	expr : expr . "DIV" expr  (10)
	expr : expr "DIV" expr .  (10)
	expr : expr . "MOD" expr  (11)
	expr : expr . "AND" expr  (12)
	expr : expr . '|' expr  (13)

	"ADD"  shift 16
	"SUB"  shift 17
	"MUL"  shift 18
	"DIV"  shift 19
	"MOD"  shift 20
	"AND"  shift 21
	'|'  shift 22
	'\n'  reduce 10
	')'  reduce 10


30: shift/reduce conflict (shift 16, reduce 11) on "ADD"
30: shift/reduce conflict (shift 17, reduce 11) on "SUB"
30: shift/reduce conflict (shift 18, reduce 11) on "MUL"
30: shift/reduce conflict (shift 19, reduce 11) on "DIV"
30: shift/reduce conflict (shift 20, reduce 11) on "MOD"
30: shift/reduce conflict (shift 21, reduce 11) on "AND"
30: shift/reduce conflict (shift 22, reduce 11) on '|'
state 30
	expr : expr . "ADD" expr  (7)
	expr : expr . "SUB" expr  (8)
	expr : expr . "MUL" expr  (9)
	expr : expr . "DIV" expr  (10)
	expr : expr . "MOD" expr  (11)
	expr : expr "MOD" expr .  (11)
	expr : expr . "AND" expr  (12)
	expr : expr . '|' expr  (13)

	"ADD"  shift 16
	"SUB"  shift 17
	"MUL"  shift 18
	"DIV"  shift 19
	"MOD"  shift 20
	"AND"  shift 21
	'|'  shift 22
	'\n'  reduce 11
	')'  reduce 11


31: shift/reduce conflict (shift 16, reduce 12) on "ADD"
31: shift/reduce conflict (shift 17, reduce 12) on "SUB"
31: shift/reduce conflict (shift 18, reduce 12) on "MUL"
31: shift/reduce conflict (shift 19, reduce 12) on "DIV"
31: shift/reduce conflict (shift 20, reduce 12) on "MOD"
31: shift/reduce conflict (shift 21, reduce 12) on "AND"
31: shift/reduce conflict (shift 22, reduce 12) on '|'
state 31
	expr : expr . "ADD" expr  (7)
	expr : expr . "SUB" expr  (8)
	expr : expr . "MUL" expr  (9)
	expr : expr . "DIV" expr  (10)
	expr : expr . "MOD" expr  (11)
	expr : expr . "AND" expr  (12)
	expr : expr "AND" expr .  (12)
	expr : expr . '|' expr  (13)

	"ADD"  shift 16
	"SUB"  shift 17
	"MUL"  shift 18
	"DIV"  shift 19
	"MOD"  shift 20
	"AND"  shift 21
	'|'  shift 22
	'\n'  reduce 12
	')'  reduce 12


32: shift/reduce conflict (shift 16, reduce 13) on "ADD"
32: shift/reduce conflict (shift 17, reduce 13) on "SUB"
32: shift/reduce conflict (shift 18, reduce 13) on "MUL"
32: shift/reduce conflict (shift 19, reduce 13) on "DIV"
32: shift/reduce conflict (shift 20, reduce 13) on "MOD"
32: shift/reduce conflict (shift 21, reduce 13) on "AND"
state 32
	expr : expr . "ADD" expr  (7)
	expr : expr . "SUB" expr  (8)
	expr : expr . "MUL" expr  (9)
	expr : expr . "DIV" expr  (10)
	expr : expr . "MOD" expr  (11)
	expr : expr . "AND" expr  (12)
	expr : expr . '|' expr  (13)
	expr : expr '|' expr .  (13)

	"ADD"  shift 16
	"SUB"  shift 17
	"MUL"  shift 18
	"DIV"  shift 19
	"MOD"  shift 20
	"AND"  shift 21
	'|'  reduce 13
	'\n'  reduce 13
	')'  reduce 13


State 12 contains 6 shift/reduce conflicts.
State 26 contains 7 shift/reduce conflicts.
State 27 contains 7 shift/reduce conflicts.
State 28 contains 7 shift/reduce conflicts.
State 29 contains 7 shift/reduce conflicts.
State 30 contains 7 shift/reduce conflicts.
State 31 contains 7 shift/reduce conflicts.
State 32 contains 6 shift/reduce conflicts.


28 terminals, 5 nonterminals
19 grammar rules, 33 states

grammar parser grammar
symbol# value# symbol
     0      0  $end
     1    256  error
     2    257  OP_ADD
     3    258  "ADD"
     4    259  OP_SUB
     5    260  "SUB"
     6    261  OP_MUL
     7    262  "MUL"
     8    263  OP_DIV
     9    264  "DIV"
    10    265  OP_MOD
    11    266  "MOD"
    12    267  OP_AND
    13    268  "AND"
    14    269  DIGIT
    15    270  LETTER
    16    124  '|'
    17     38  '&'
    18     43  '+'
    19     45  '-'
    20     42  '*'
    21     47  '/'
    22     37  '%'
    23    271  UMINUS
    24     10  '\n'
    25     61  '='
    26     40  '('
    27     41  ')'
    28    272  $accept
    29    273  list
    30    274  stat
    31    275  expr
    32    276  number