硬汉嵌入式论坛

 找回密码
 立即注册
查看: 713|回复: 1
收起左侧

[IAR] IAR链接器支持将剩余RAM分配给指定空间(比如栈、堆)

[复制链接]

210

主题

1045

回帖

1685

积分

至尊会员

More we do, more we can do.

积分
1685
发表于 2022-10-11 13:40:16 | 显示全部楼层 |阅读模式
本帖最后由 emwin 于 2022-10-11 13:48 编辑

环境:IAR for ARM 8.0+  《The linker configuration file》章节
image.png
expanding size
The block will expand to use all available space in the memory range where it is placed.

示例:
[C] 纯文本查看 复制代码
/* Create a block with a minimum size for the heap that will use
all remaining space in its memory range */
define block HEAP with minimum size = 4K, expanding size,
alignment = 8 { };





回复

使用道具 举报

1万

主题

6万

回帖

10万

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
106978
QQ
发表于 2022-10-11 15:54:39 | 显示全部楼层
谢谢分享。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|小黑屋|Archiver|手机版|硬汉嵌入式论坛

GMT+8, 2024-5-12 22:45 , Processed in 0.167463 second(s), 28 queries .

Powered by Discuz! X3.4 Licensed

Copyright © 2001-2023, Tencent Cloud.

快速回复 返回顶部 返回列表