Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(303)

Unified Diff: src/compiler/ppc/code-generator-ppc.cc

Issue 2905453002: PPC: Remove unnecessary frsp before stfs in codegen (Closed)
Patch Set: Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/ppc/code-generator-ppc.cc
diff --git a/src/compiler/ppc/code-generator-ppc.cc b/src/compiler/ppc/code-generator-ppc.cc
index e62e725c4dfdc5a31445c8cd065dc911d455ca76..e3fddd0dbc5a1da0ab5da8597625ee4a53d348b6 100644
--- a/src/compiler/ppc/code-generator-ppc.cc
+++ b/src/compiler/ppc/code-generator-ppc.cc
@@ -587,11 +587,12 @@ Condition FlagsConditionToCondition(FlagsCondition condition, ArchOpcode op) {
AddressingMode mode = kMode_None; \
MemOperand operand = i.MemoryOperand(&mode, &index); \
DoubleRegister value = i.InputDoubleRegister(index); \
- __ frsp(kScratchDoubleReg, value); \
+ /* removed frsp as instruction-selector checked */ \
+ /* value to be kFloat32 */ \
if (mode == kMode_MRI) { \
- __ stfs(kScratchDoubleReg, operand); \
+ __ stfs(value, operand); \
} else { \
- __ stfsx(kScratchDoubleReg, operand); \
+ __ stfsx(value, operand); \
} \
DCHECK_EQ(LeaveRC, i.OutputRCBit()); \
} while (0)
@@ -699,11 +700,13 @@ Condition FlagsConditionToCondition(FlagsCondition condition, ArchOpcode op) {
__ bge(&done); \
DoubleRegister value = i.InputDoubleRegister(3); \
__ frsp(kScratchDoubleReg, value); \
+ /* removed frsp as instruction-selector checked */ \
+ /* value to be kFloat32 */ \
if (mode == kMode_MRI) { \
- __ stfs(kScratchDoubleReg, operand); \
+ __ stfs(value, operand); \
} else { \
CleanUInt32(offset); \
- __ stfsx(kScratchDoubleReg, operand); \
+ __ stfsx(value, operand); \
} \
__ bind(&done); \
DCHECK_EQ(LeaveRC, i.OutputRCBit()); \
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698