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

Unified Diff: src/ia32/macro-assembler-ia32.cc

Issue 197037: Use fucomi instruction to compare floats and put results directly into EFLAGS... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 3 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
Index: src/ia32/macro-assembler-ia32.cc
===================================================================
--- src/ia32/macro-assembler-ia32.cc (revision 2836)
+++ src/ia32/macro-assembler-ia32.cc (working copy)
@@ -319,11 +319,17 @@
void MacroAssembler::FCmp() {
- fcompp();
- push(eax);
- fnstsw_ax();
- sahf();
- pop(eax);
+ if (CpuFeatures::IsSupported(CpuFeatures::CMOV)) {
+ fucomip();
+ ffree(0);
+ fincstp();
+ } else {
+ fucompp();
+ push(eax);
+ fnstsw_ax();
+ sahf();
+ pop(eax);
+ }
}

Powered by Google App Engine
This is Rietveld 408576698