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

Side by Side Diff: src/x64/codegen-x64.h

Issue 1944001: Port inline swapping of elements for the sort function in array.js... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 10 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/ia32/macro-assembler-ia32.cc ('k') | src/x64/macro-assembler-x64.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 1015 matching lines...) Expand 10 before | Expand all | Expand 10 after
1026 Register addr_; 1026 Register addr_;
1027 Register scratch_; 1027 Register scratch_;
1028 1028
1029 #ifdef DEBUG 1029 #ifdef DEBUG
1030 void Print() { 1030 void Print() {
1031 PrintF("RecordWriteStub (object reg %d), (addr reg %d), (scratch reg %d)\n", 1031 PrintF("RecordWriteStub (object reg %d), (addr reg %d), (scratch reg %d)\n",
1032 object_.code(), addr_.code(), scratch_.code()); 1032 object_.code(), addr_.code(), scratch_.code());
1033 } 1033 }
1034 #endif 1034 #endif
1035 1035
1036 // Minor key encoding in 12 bits of three registers (object, address and 1036 // Minor key encoding in 12 bits. 4 bits for each of the three
1037 // scratch) OOOOAAAASSSS. 1037 // registers (object, address and scratch) OOOOAAAASSSS.
1038 class ScratchBits : public BitField<uint32_t, 0, 4> {}; 1038 class ScratchBits : public BitField<uint32_t, 0, 4> {};
1039 class AddressBits : public BitField<uint32_t, 4, 4> {}; 1039 class AddressBits : public BitField<uint32_t, 4, 4> {};
1040 class ObjectBits : public BitField<uint32_t, 8, 4> {}; 1040 class ObjectBits : public BitField<uint32_t, 8, 4> {};
1041 1041
1042 Major MajorKey() { return RecordWrite; } 1042 Major MajorKey() { return RecordWrite; }
1043 1043
1044 int MinorKey() { 1044 int MinorKey() {
1045 // Encode the registers. 1045 // Encode the registers.
1046 return ObjectBits::encode(object_.code()) | 1046 return ObjectBits::encode(object_.code()) |
1047 AddressBits::encode(addr_.code()) | 1047 AddressBits::encode(addr_.code()) |
1048 ScratchBits::encode(scratch_.code()); 1048 ScratchBits::encode(scratch_.code());
1049 } 1049 }
1050 }; 1050 };
1051 1051
1052 1052
1053 } } // namespace v8::internal 1053 } } // namespace v8::internal
1054 1054
1055 #endif // V8_X64_CODEGEN_X64_H_ 1055 #endif // V8_X64_CODEGEN_X64_H_
OLDNEW
« no previous file with comments | « src/ia32/macro-assembler-ia32.cc ('k') | src/x64/macro-assembler-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698