-
Notifications
You must be signed in to change notification settings - Fork 5.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[IR Dialect] ⚔Elden chapter 1.1⚔ #55256
Conversation
你的PR提交成功,感谢你对开源项目的贡献! |
|
||
private: | ||
char *data_; | ||
uint32_t size_; | ||
ParamKey DataString; |
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.
- data_已经malloc放到了heap了,这里如果再存一份string的话,成员变量重复了
- 从框架内规范而言,类的成员变量是小写,且以下划线作为区分,规范写法应该是 data_string_
关于上述①,已与内部进行讨论,看是否可以移除malloc,只保留 data_string_即可
这里补充下一些 Storage 的设计考量(后续会以「设计文档」方式发布到Community社区)。 可以看到,在新 IR 里有很多 Storage 的设计,比如每个Attribute 都仅关联了一个对应的 Storage 指针。
这里涉及的内容比较多,我来写个 《Storage 技术设计剖析》专栏吧 |
@Liyulingyue 这个 PR 在现有的规范下可能还合入不了,StringAtrribute这个比较特殊,可以先搁置下。可以优化 IntArrayAttribute的接口:
|
Sorry to inform you that 46c87fa's CIs have passed for more than 7 days. To prevent PR conflicts, you need to re-run all CIs manually. |
先close掉了,string这个内部同学为了避免歧义,修改为了AsString()接口 |
PR types
Others
PR changes
Others
Description
add const return in StrAttributeStorage
#55205 case 1.1
🎉让大卢恩再次获得力量🎉