There are three components: Client, Emitter, Absorber
- Works locally
- Communicates with Emitter via unix socket
What it does:
- Parses command line arguments
- Fixes file paths
- Defines a version of desired CLANG
- Generates message to EMITTER via protobuf
So, the aim for this component is to parse command line options, normalize paths and send further.
-
Works locally
-
Works as a daemon
-
Communicates with Client via unix socket
-
Communicates with Absorber via TCP/IP network
-
There are two kinds of local cache:
- DIRECT: checks DEPS files generated by previous compilation
- SIMPLE: checks preprocessed file content
-
Cache key is a hash of :
- Compiler version
- Command-line arguments
- Source file
What it does:
-
Checks if a source file is in DIRECT cache
- If so, output data
-
Preprocess the source file
-
Checks if the preprocessed file is in SIMPLE cache
- If so, output data
-
There is no cache entry for the particular source file
-
Adds entry for compilation to a local queue
-
There two kinds of worker which process items from the queue:
-
Local worker: compiles file locally
-
Remote worker: generate protobuf message to Absorber via protobuf with:
- Preprocessed source file
- Desired compiler version
- Particular set of compilation flags
-
So, the aim for this component is to check if there is a source file is local caches (DIRECT and SIMPLE). If no, send a message for a remote compilation or compile it locally.
- Works on remote HW
- Works with preprocessed source files
- Communicates with EMITTER via network
What it does:
- Receives a message from EMITTER
- Compiles the preprocessed source file from message using a desired compiler
- Sends result back
So, the aim for this component is to compile the source file and send an output object file back.