mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-14 14:17:20 +00:00
bgpd: Optimize memory usage for bgp_notify struct
``` struct bgp_notify { uint8_t code; /* 0 1 */ uint8_t subcode; /* 1 1 */ bgp_size_t length; /* 2 2 */ _Bool hard_reset; /* 4 1 */ /* XXX 3 bytes hole, try to pack */ char * data; /* 8 8 */ uint8_t * raw_data; /* 16 8 */ /* size: 24, cachelines: 1, members: 6 */ /* sum members: 21, holes: 1, sum holes: 3 */ /* last cacheline: 24 bytes */ }; /* saved 16 bytes! */ ``` Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
This commit is contained in:
parent
f8755d7f86
commit
7133cce196
@ -888,10 +888,10 @@ struct peer_group {
|
|||||||
struct bgp_notify {
|
struct bgp_notify {
|
||||||
uint8_t code;
|
uint8_t code;
|
||||||
uint8_t subcode;
|
uint8_t subcode;
|
||||||
char *data;
|
|
||||||
bgp_size_t length;
|
bgp_size_t length;
|
||||||
uint8_t *raw_data;
|
|
||||||
bool hard_reset;
|
bool hard_reset;
|
||||||
|
char *data;
|
||||||
|
uint8_t *raw_data;
|
||||||
};
|
};
|
||||||
|
|
||||||
/* Next hop self address. */
|
/* Next hop self address. */
|
||||||
|
Loading…
Reference in New Issue
Block a user