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

Side by Side Diff: test/cctest/test-macro-assembler-mips64.cc

Issue 2556793003: MIPS[64]: Fix `MIPS: Improve Float(32|64)(Max|Min)`. (Closed)
Patch Set: Created 4 years 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 1992 matching lines...) Expand 10 before | Expand all | Expand 10 after
2003 2003
2004 #undef FLOAT_MIN_MAX 2004 #undef FLOAT_MIN_MAX
2005 2005
2006 __ jr(ra); 2006 __ jr(ra);
2007 __ nop(); 2007 __ nop();
2008 2008
2009 // Generate out-of-line cases. 2009 // Generate out-of-line cases.
2010 __ bind(&ool_min_abc); 2010 __ bind(&ool_min_abc);
2011 __ Float32MinOutOfLine(a, b, c); 2011 __ Float32MinOutOfLine(a, b, c);
2012 __ b(&done_min_abc); 2012 __ b(&done_min_abc);
2013 __ nop();
ivica.bogosavljevic 2016/12/07 15:05:04 you shouldn't use b() outside of MacroAssembler, u
Ilija.Pavlovic1 2016/12/08 13:50:06 Using Branch macros will be applied also on macro-
2013 2014
2014 __ bind(&ool_min_aab); 2015 __ bind(&ool_min_aab);
2015 __ Float32MinOutOfLine(a, a, b); 2016 __ Float32MinOutOfLine(a, a, b);
2016 __ b(&done_min_aab); 2017 __ b(&done_min_aab);
2018 __ nop();
2017 2019
2018 __ bind(&ool_min_aba); 2020 __ bind(&ool_min_aba);
2019 __ Float32MinOutOfLine(a, b, a); 2021 __ Float32MinOutOfLine(a, b, a);
2020 __ b(&done_min_aba); 2022 __ b(&done_min_aba);
2023 __ nop();
2021 2024
2022 __ bind(&ool_max_abc); 2025 __ bind(&ool_max_abc);
2023 __ Float32MaxOutOfLine(a, b, c); 2026 __ Float32MaxOutOfLine(a, b, c);
2024 __ b(&done_max_abc); 2027 __ b(&done_max_abc);
2028 __ nop();
2025 2029
2026 __ bind(&ool_max_aab); 2030 __ bind(&ool_max_aab);
2027 __ Float32MaxOutOfLine(a, a, b); 2031 __ Float32MaxOutOfLine(a, a, b);
2028 __ b(&done_max_aab); 2032 __ b(&done_max_aab);
2033 __ nop();
2029 2034
2030 __ bind(&ool_max_aba); 2035 __ bind(&ool_max_aba);
2031 __ Float32MaxOutOfLine(a, b, a); 2036 __ Float32MaxOutOfLine(a, b, a);
2032 __ b(&done_max_aba); 2037 __ b(&done_max_aba);
2038 __ nop();
2033 2039
2034 CodeDesc desc; 2040 CodeDesc desc;
2035 masm->GetCode(&desc); 2041 masm->GetCode(&desc);
2036 Handle<Code> code = masm->isolate()->factory()->NewCode( 2042 Handle<Code> code = masm->isolate()->factory()->NewCode(
2037 desc, Code::ComputeFlags(Code::STUB), Handle<Code>()); 2043 desc, Code::ComputeFlags(Code::STUB), Handle<Code>());
2038 #ifdef DEBUG 2044 #ifdef DEBUG
2039 OFStream os(stdout); 2045 OFStream os(stdout);
2040 code->Print(os); 2046 code->Print(os);
2041 #endif 2047 #endif
2042 return FUNCTION_CAST<::F4>(code->entry()); 2048 return FUNCTION_CAST<::F4>(code->entry());
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
2146 2152
2147 #undef FLOAT_MIN_MAX 2153 #undef FLOAT_MIN_MAX
2148 2154
2149 __ jr(ra); 2155 __ jr(ra);
2150 __ nop(); 2156 __ nop();
2151 2157
2152 // Generate out-of-line cases. 2158 // Generate out-of-line cases.
2153 __ bind(&ool_min_abc); 2159 __ bind(&ool_min_abc);
2154 __ Float64MinOutOfLine(a, b, c); 2160 __ Float64MinOutOfLine(a, b, c);
2155 __ b(&done_min_abc); 2161 __ b(&done_min_abc);
2162 __ nop();
2156 2163
2157 __ bind(&ool_min_aab); 2164 __ bind(&ool_min_aab);
2158 __ Float64MinOutOfLine(a, a, b); 2165 __ Float64MinOutOfLine(a, a, b);
2159 __ b(&done_min_aab); 2166 __ b(&done_min_aab);
2167 __ nop();
2160 2168
2161 __ bind(&ool_min_aba); 2169 __ bind(&ool_min_aba);
2162 __ Float64MinOutOfLine(a, b, a); 2170 __ Float64MinOutOfLine(a, b, a);
2163 __ b(&done_min_aba); 2171 __ b(&done_min_aba);
2172 __ nop();
2164 2173
2165 __ bind(&ool_max_abc); 2174 __ bind(&ool_max_abc);
2166 __ Float64MaxOutOfLine(a, b, c); 2175 __ Float64MaxOutOfLine(a, b, c);
2167 __ b(&done_max_abc); 2176 __ b(&done_max_abc);
2177 __ nop();
2168 2178
2169 __ bind(&ool_max_aab); 2179 __ bind(&ool_max_aab);
2170 __ Float64MaxOutOfLine(a, a, b); 2180 __ Float64MaxOutOfLine(a, a, b);
2171 __ b(&done_max_aab); 2181 __ b(&done_max_aab);
2182 __ nop();
2172 2183
2173 __ bind(&ool_max_aba); 2184 __ bind(&ool_max_aba);
2174 __ Float64MaxOutOfLine(a, b, a); 2185 __ Float64MaxOutOfLine(a, b, a);
2175 __ b(&done_max_aba); 2186 __ b(&done_max_aba);
2187 __ nop();
2176 2188
2177 CodeDesc desc; 2189 CodeDesc desc;
2178 masm->GetCode(&desc); 2190 masm->GetCode(&desc);
2179 Handle<Code> code = masm->isolate()->factory()->NewCode( 2191 Handle<Code> code = masm->isolate()->factory()->NewCode(
2180 desc, Code::ComputeFlags(Code::STUB), Handle<Code>()); 2192 desc, Code::ComputeFlags(Code::STUB), Handle<Code>());
2181 #ifdef DEBUG 2193 #ifdef DEBUG
2182 OFStream os(stdout); 2194 OFStream os(stdout);
2183 code->Print(os); 2195 code->Print(os);
2184 #endif 2196 #endif
2185 return FUNCTION_CAST<::F4>(code->entry()); 2197 return FUNCTION_CAST<::F4>(code->entry());
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
2248 2260
2249 CHECK_MINMAX(0.0, nan_a, nan_a, nan_a); 2261 CHECK_MINMAX(0.0, nan_a, nan_a, nan_a);
2250 CHECK_MINMAX(nan_a, 0.0, nan_a, nan_a); 2262 CHECK_MINMAX(nan_a, 0.0, nan_a, nan_a);
2251 CHECK_MINMAX(nan_a, nan_b, nan_a, nan_a); 2263 CHECK_MINMAX(nan_a, nan_b, nan_a, nan_a);
2252 CHECK_MINMAX(nan_b, nan_a, nan_b, nan_b); 2264 CHECK_MINMAX(nan_b, nan_a, nan_b, nan_b);
2253 2265
2254 #undef CHECK_MINMAX 2266 #undef CHECK_MINMAX
2255 } 2267 }
2256 2268
2257 #undef __ 2269 #undef __
OLDNEW
« src/crankshaft/mips64/lithium-codegen-mips64.cc ('K') | « test/cctest/test-macro-assembler-mips.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698