typedef struct {
short device;
long type;
char plen;
} __attribute__ ((packed)) test_pack_t;
struct test_pack {
short device;
long type;
char plen;
} __attribute__ ((packed));
gcc 强制内存对齐格式
原创NoName51C_T_O 博主文章分类:杂项随手笔记 ©著作权
©著作权归作者所有:来自51CTO博客作者NoName51C_T_O的原创作品,请联系作者获取转载授权,否则将追究法律责任
上一篇:在KEIL中合并两个HEX文件
下一篇:git获取全部分支
提问和评论都可以,用心的回复会被更多人看到
评论
发布评论
相关文章
-
关于bmp 4字节对齐
Windows规定一个扫描行所占的字节数必须是4的倍数(即以long为单位),不足的以0填充,开
bmp 图像处理 字节对齐 图像显示 灰度变换 -
5G移动通信系统内的三朵云架构
X86架构和ARM架构是主流的两种CPU架构,X86架构的CPU是PC服务器行业的老大,ARM架构的CPU则是移动端的老大。 X86架构和arm架构实际上就是CISC与RISC之间的区别,很多用户不
5G移动通信系统内的三朵云架构 云计算 精简指令 指令集 服务器