| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_X64. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_X64. |
| 6 #if defined(TARGET_ARCH_X64) | 6 #if defined(TARGET_ARCH_X64) |
| 7 | 7 |
| 8 #include "vm/intrinsifier.h" | 8 #include "vm/intrinsifier.h" |
| 9 | 9 |
| 10 #include "vm/assembler.h" | 10 #include "vm/assembler.h" |
| (...skipping 1847 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1858 // RDI: Start address to copy from (untagged). | 1858 // RDI: Start address to copy from (untagged). |
| 1859 | 1859 |
| 1860 __ Bind(&ok); | 1860 __ Bind(&ok); |
| 1861 __ ret(); | 1861 __ ret(); |
| 1862 | 1862 |
| 1863 __ Bind(&fall_through); | 1863 __ Bind(&fall_through); |
| 1864 } | 1864 } |
| 1865 | 1865 |
| 1866 | 1866 |
| 1867 // TODO(srdjan): Add combinations (one-byte/two-byte/external strings). | 1867 // TODO(srdjan): Add combinations (one-byte/two-byte/external strings). |
| 1868 void StringEquality(Assembler* assembler, intptr_t string_cid) { | 1868 static void StringEquality(Assembler* assembler, intptr_t string_cid) { |
| 1869 Label fall_through, is_true, is_false, loop; | 1869 Label fall_through, is_true, is_false, loop; |
| 1870 __ movq(RAX, Address(RSP, + 2 * kWordSize)); // This. | 1870 __ movq(RAX, Address(RSP, + 2 * kWordSize)); // This. |
| 1871 __ movq(RCX, Address(RSP, + 1 * kWordSize)); // Other. | 1871 __ movq(RCX, Address(RSP, + 1 * kWordSize)); // Other. |
| 1872 | 1872 |
| 1873 // Are identical? | 1873 // Are identical? |
| 1874 __ cmpq(RAX, RCX); | 1874 __ cmpq(RAX, RCX); |
| 1875 __ j(EQUAL, &is_true, Assembler::kNearJump); | 1875 __ j(EQUAL, &is_true, Assembler::kNearJump); |
| 1876 | 1876 |
| 1877 // Is other OneByteString? | 1877 // Is other OneByteString? |
| 1878 __ testq(RCX, Immediate(kSmiTagMask)); | 1878 __ testq(RCX, Immediate(kSmiTagMask)); |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2009 // Set return value to Isolate::current_tag_. | 2009 // Set return value to Isolate::current_tag_. |
| 2010 __ movq(RAX, Address(RBX, Isolate::current_tag_offset())); | 2010 __ movq(RAX, Address(RBX, Isolate::current_tag_offset())); |
| 2011 __ ret(); | 2011 __ ret(); |
| 2012 } | 2012 } |
| 2013 | 2013 |
| 2014 #undef __ | 2014 #undef __ |
| 2015 | 2015 |
| 2016 } // namespace dart | 2016 } // namespace dart |
| 2017 | 2017 |
| 2018 #endif // defined TARGET_ARCH_X64 | 2018 #endif // defined TARGET_ARCH_X64 |
| OLD | NEW |