OLD | NEW |
1 // Copyright 2009 the V8 project authors. All rights reserved. | 1 // Copyright 2009 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 7738 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7749 int CompareStub::MinorKey() { | 7749 int CompareStub::MinorKey() { |
7750 // Encode the three parameters in a unique 16 bit value. | 7750 // Encode the three parameters in a unique 16 bit value. |
7751 ASSERT(static_cast<unsigned>(cc_) < (1 << 14)); | 7751 ASSERT(static_cast<unsigned>(cc_) < (1 << 14)); |
7752 int nnn_value = (never_nan_nan_ ? 2 : 0); | 7752 int nnn_value = (never_nan_nan_ ? 2 : 0); |
7753 if (cc_ != equal) nnn_value = 0; // Avoid duplicate stubs. | 7753 if (cc_ != equal) nnn_value = 0; // Avoid duplicate stubs. |
7754 return (static_cast<unsigned>(cc_) << 2) | nnn_value | (strict_ ? 1 : 0); | 7754 return (static_cast<unsigned>(cc_) << 2) | nnn_value | (strict_ ? 1 : 0); |
7755 } | 7755 } |
7756 | 7756 |
7757 | 7757 |
7758 const char* CompareStub::GetName() { | 7758 const char* CompareStub::GetName() { |
7759 switch(cc_) { | 7759 switch (cc_) { |
7760 case less: return "CompareStub_LT"; | 7760 case less: return "CompareStub_LT"; |
7761 case greater: return "CompareStub_GT"; | 7761 case greater: return "CompareStub_GT"; |
7762 case less_equal: return "CompareStub_LE"; | 7762 case less_equal: return "CompareStub_LE"; |
7763 case greater_equal: return "CompareStub_GE"; | 7763 case greater_equal: return "CompareStub_GE"; |
7764 case not_equal: { | 7764 case not_equal: { |
7765 if (strict_) { | 7765 if (strict_) { |
7766 if (never_nan_nan_) { | 7766 if (never_nan_nan_) { |
7767 return "CompareStub_NE_STRICT_NO_NAN"; | 7767 return "CompareStub_NE_STRICT_NO_NAN"; |
7768 } else { | 7768 } else { |
7769 return "CompareStub_NE_STRICT"; | 7769 return "CompareStub_NE_STRICT"; |
(...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8112 masm.GetCode(&desc); | 8112 masm.GetCode(&desc); |
8113 // Call the function from C++. | 8113 // Call the function from C++. |
8114 return FUNCTION_CAST<ModuloFunction>(buffer); | 8114 return FUNCTION_CAST<ModuloFunction>(buffer); |
8115 } | 8115 } |
8116 | 8116 |
8117 #endif | 8117 #endif |
8118 | 8118 |
8119 #undef __ | 8119 #undef __ |
8120 | 8120 |
8121 } } // namespace v8::internal | 8121 } } // namespace v8::internal |
OLD | NEW |