6270 – XMMREGS not preserved on indirect function call

D issues are now tracked on GitHub. This Bugzilla instance remains as a read-only archive.
Issue 6270 - XMMREGS not preserved on indirect function call
Summary: XMMREGS not preserved on indirect function call
Status: RESOLVED FIXED
Alias: None
Product: D
Classification: Unclassified
Component: dmd (show other issues)
Version: D2
Hardware: x86_64 FreeBSD
: P2 normal
Assignee: No Owner
URL:
Keywords: patch, wrong-code
: 6042 (view as issue list)
Depends on:
Blocks:
Reported: 2011年07月08日 13:56 UTC by Martin Nowak
Modified: 2011年08月28日 08:40 UTC (History)
1 user (show)

See Also:


Attachments
Add an attachment (proposed patch, testcase, etc.)

Note You need to log in before you can comment on or make changes to this issue.
Description Martin Nowak 2011年07月08日 13:56:34 UTC
class XMMPainter
{
 float call()
 {
 return sumFloats(0.0f, 0.0f);
 }
 static float sumFloats(float a, float b)
 {
 return a + b;
 }
}
void testXMM()
{
 auto painter = new XMMPainter;
 assert(XMMPainter.sumFloats(20, painter.call()) == 20.0f);
}
---
The expression painter.call() is evaluated after 20 has been loaded into xmm1, but the register is not saved.
Comment 1 Martin Nowak 2011年07月08日 14:48:46 UTC
https://github.com/D-Programming-Language/dmd/pull/217 
Comment 3 Martin Nowak 2011年08月28日 08:40:42 UTC
*** Issue 6042 has been marked as a duplicate of this issue. ***


AltStyle によって変換されたページ (->オリジナル) /