P4C
The P4 Compiler
Loading...
Searching...
No Matches
pad_alignment.h
1
19
#ifndef PAD_ALIGNMENT_H_
20
#define PAD_ALIGNMENT_H_
21
22
#include "lib/algorithm.h"
23
24
static
inline
int
getAlignment(
int
bitSize) {
25
int
nextByteBoundary = 8 * ROUNDUP(bitSize, 8);
26
return
(nextByteBoundary - bitSize);
27
}
28
29
#endif
/* PAD_ALIGNMENT_H_ */
backends
tofino
bf-p4c
lib
pad_alignment.h
Generated by
1.12.0