-
Notifications
You must be signed in to change notification settings - Fork 58
Conversation
docs/LoongArch-ELF-ABI-EN.adoc
.. A place to store the values of saved registers. | ||
.. A place for local data storage. | ||
|
||
. The stack grows downwards (towards lower addresses) and the stack pointer shall be aligned to a 128-bit boundary upon procedure entry. The first argument passed on the stack is located at offset zero of the stack pointer on function entry; following arguments are stored at correspondingly higher addresses. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
目前的 gcc 代码中 ILP32 使用 64 位栈对齐,LP64 使用 128 位栈对齐:https://github.com/loongson/gcc/blob/loongarch-12/gcc/config/loongarch/loongarch.h#L703
要改为都使用 128 位对齐吗?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
目前这块只包含lp64d的情况,而且也明确了在lp64d的情况下,这边写的。32位的还没成熟,暂不考虑包含在文档中。
@@ -316,7 +317,7 @@ v1.00 定义的指令集架构 | |||
|
|||
|`ilp32s` / `default` | |||
|GNU/Linux | |||
|`loongarch32-linux-gnusfp` | |||
|`loongarch32-linux-gnusf` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
gnu后面加字符,这个感觉有点怪怪的,而且存在对现有工具的兼容性问题吧?比如一些类似*-linux-gnu这种匹配代码。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
对,这些内容不在这讨论。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
gnu后面加字符,这个感觉有点怪怪的,而且存在对现有工具的兼容性问题吧?比如一些类似*-linux-gnu这种匹配代码。
我感觉加在loongarch32更合适,loongarch32sf-linux-gnu loongarch32f32-linux-gnu loongarch32f64-linux-gnu
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok.
#25 已经合并了,请把重复的补丁去掉,重新提交一下。 |
Add procedure calling convention.