public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/106200] New: Shrink-wrapping opportunity releated to function call
@ 2022-07-05 13:08 zhongyunde at huawei dot com
2022-07-05 13:11 ` [Bug rtl-optimization/106200] " pinskia at gcc dot gnu.org
2022-07-05 22:27 ` [Bug tree-optimization/106200] " pinskia at gcc dot gnu.org
0 siblings, 2 replies; 3+ messages in thread
From: zhongyunde at huawei dot com @ 2022-07-05 13:08 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106200
Bug ID: 106200
Summary: Shrink-wrapping opportunity releated to function call
Product: gcc
Version: 13.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
Assignee: unassigned at gcc dot gnu.org
Reporter: zhongyunde at huawei dot com
Target Milestone: ---
case:https://godbolt.org/z/sc5rTzaeb
```
double advance(double dt, double dx, double dy, double dz)
{
double dSquared = dx * dx + dy * dy + dz * dz;
double mag = dt / (dSquared * std::sqrt(dSquared));
return mag;
}
```
we can the llvm Shrink-wrapping, so the spill only in the branch where *call
sqrt*, so there is no spill if goto the branch where use the *insn fsqrt*.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug rtl-optimization/106200] Shrink-wrapping opportunity releated to function call
2022-07-05 13:08 [Bug c/106200] New: Shrink-wrapping opportunity releated to function call zhongyunde at huawei dot com
@ 2022-07-05 13:11 ` pinskia at gcc dot gnu.org
2022-07-05 22:27 ` [Bug tree-optimization/106200] " pinskia at gcc dot gnu.org
1 sibling, 0 replies; 3+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-07-05 13:11 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106200
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |missed-optimization
Severity|normal |enhancement
Component|c |rtl-optimization
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug tree-optimization/106200] Shrink-wrapping opportunity releated to function call
2022-07-05 13:08 [Bug c/106200] New: Shrink-wrapping opportunity releated to function call zhongyunde at huawei dot com
2022-07-05 13:11 ` [Bug rtl-optimization/106200] " pinskia at gcc dot gnu.org
@ 2022-07-05 22:27 ` pinskia at gcc dot gnu.org
1 sibling, 0 replies; 3+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-07-05 22:27 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106200
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Created attachment 53260
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=53260&action=edit
full testcase
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-07-05 22:27 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-05 13:08 [Bug c/106200] New: Shrink-wrapping opportunity releated to function call zhongyunde at huawei dot com
2022-07-05 13:11 ` [Bug rtl-optimization/106200] " pinskia at gcc dot gnu.org
2022-07-05 22:27 ` [Bug tree-optimization/106200] " pinskia at gcc dot gnu.org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).