Parker Schuh | e4a70d6 | 2017-12-27 20:10:20 -0800 | [diff] [blame] | 1 | cc_library( |
Austin Schuh | 6b6dfa5 | 2019-06-12 20:16:20 -0700 | [diff] [blame] | 2 | name = "epoll", |
| 3 | srcs = ["epoll.cc"], |
| 4 | hdrs = ["epoll.h"], |
| 5 | deps = [ |
| 6 | "//aos/logging", |
| 7 | "//aos/time", |
| 8 | ], |
| 9 | ) |
| 10 | |
| 11 | cc_library( |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 12 | name = "raw-event-loop", |
| 13 | hdrs = ["raw-event-loop.h"], |
| 14 | deps = [ |
| 15 | "//aos:queues", |
| 16 | "//aos/time", |
| 17 | ], |
Parker Schuh | e4a70d6 | 2017-12-27 20:10:20 -0800 | [diff] [blame] | 18 | ) |
| 19 | |
| 20 | cc_library( |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 21 | name = "event-loop", |
| 22 | srcs = ["event-loop-tmpl.h"], |
| 23 | hdrs = [ |
| 24 | "event-loop.h", |
| 25 | "raw-event-loop.h", |
| 26 | ], |
| 27 | visibility = ["//visibility:public"], |
| 28 | deps = [ |
| 29 | ":raw-event-loop", |
| 30 | "//aos:queues", |
| 31 | "//aos/time", |
| 32 | ], |
Parker Schuh | e4a70d6 | 2017-12-27 20:10:20 -0800 | [diff] [blame] | 33 | ) |
| 34 | |
| 35 | cc_library( |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 36 | name = "shm-event-loop", |
| 37 | srcs = ["shm-event-loop.cc"], |
| 38 | hdrs = ["shm-event-loop.h"], |
| 39 | visibility = ["//visibility:public"], |
| 40 | deps = [ |
Austin Schuh | 6b6dfa5 | 2019-06-12 20:16:20 -0700 | [diff] [blame] | 41 | ":epoll", |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 42 | ":event-loop", |
Austin Schuh | 3115a20 | 2019-05-27 21:02:14 -0700 | [diff] [blame] | 43 | "//aos:init", |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 44 | "//aos:queues", |
| 45 | "//aos/logging", |
Austin Schuh | 52d325c | 2019-06-23 18:59:06 -0700 | [diff] [blame] | 46 | "//aos/util:phased_loop", |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 47 | ], |
Parker Schuh | e4a70d6 | 2017-12-27 20:10:20 -0800 | [diff] [blame] | 48 | ) |
| 49 | |
| 50 | cc_test( |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 51 | name = "shm-event-loop_test", |
| 52 | srcs = ["shm-event-loop_test.cc"], |
Austin Schuh | 6b6dfa5 | 2019-06-12 20:16:20 -0700 | [diff] [blame] | 53 | shard_count = 5, |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 54 | deps = [ |
| 55 | ":event-loop_param_test", |
| 56 | ":shm-event-loop", |
| 57 | "//aos/testing:test_shm", |
| 58 | ], |
Parker Schuh | e4a70d6 | 2017-12-27 20:10:20 -0800 | [diff] [blame] | 59 | ) |
| 60 | |
| 61 | cc_library( |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 62 | name = "event-loop_param_test", |
| 63 | testonly = True, |
| 64 | srcs = ["event-loop_param_test.cc"], |
| 65 | hdrs = ["event-loop_param_test.h"], |
| 66 | deps = [ |
Austin Schuh | 9fe68f7 | 2019-08-10 19:32:03 -0700 | [diff] [blame^] | 67 | ":event-loop", |
| 68 | "//aos/logging:queue_logging", |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 69 | "//aos/testing:googletest", |
| 70 | ], |
Parker Schuh | e4a70d6 | 2017-12-27 20:10:20 -0800 | [diff] [blame] | 71 | ) |
Neil Balch | c8f41ed | 2018-01-20 22:06:53 -0800 | [diff] [blame] | 72 | |
| 73 | cc_test( |
Austin Schuh | 7267c53 | 2019-05-19 19:55:53 -0700 | [diff] [blame] | 74 | name = "simulated_event_loop_test", |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 75 | srcs = ["simulated-event-loop_test.cc"], |
| 76 | deps = [ |
| 77 | ":event-loop_param_test", |
Austin Schuh | 7267c53 | 2019-05-19 19:55:53 -0700 | [diff] [blame] | 78 | ":simulated_event_loop", |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 79 | "//aos/testing:googletest", |
| 80 | ], |
Neil Balch | c8f41ed | 2018-01-20 22:06:53 -0800 | [diff] [blame] | 81 | ) |
| 82 | |
| 83 | cc_library( |
Austin Schuh | 7267c53 | 2019-05-19 19:55:53 -0700 | [diff] [blame] | 84 | name = "simulated_event_loop", |
Austin Schuh | 82c0c82 | 2019-05-27 19:55:20 -0700 | [diff] [blame] | 85 | testonly = True, |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 86 | srcs = ["simulated-event-loop.cc"], |
| 87 | hdrs = ["simulated-event-loop.h"], |
Austin Schuh | 7267c53 | 2019-05-19 19:55:53 -0700 | [diff] [blame] | 88 | visibility = ["//visibility:public"], |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 89 | deps = [ |
| 90 | ":event-loop", |
| 91 | "//aos:queues", |
James Kuszmaul | c79768b | 2019-02-18 15:08:44 -0800 | [diff] [blame] | 92 | "//aos/logging", |
Austin Schuh | 82c0c82 | 2019-05-27 19:55:20 -0700 | [diff] [blame] | 93 | "//aos/testing:test_logging", |
Austin Schuh | 52d325c | 2019-06-23 18:59:06 -0700 | [diff] [blame] | 94 | "//aos/util:phased_loop", |
Austin Schuh | a1654ed | 2019-01-27 17:24:54 -0800 | [diff] [blame] | 95 | ], |
Neil Balch | c8f41ed | 2018-01-20 22:06:53 -0800 | [diff] [blame] | 96 | ) |