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

Side by Side Diff: src/x64/macro-assembler-x64.cc

Issue 141043: X64 implementation: Emit correct merge code for virtual frames at CFG merges. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 6 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
OLDNEW
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 249 matching lines...) Expand 10 before | Expand all | Expand 10 after
260 movq(kScratchRegister, Immediate(x)); 260 movq(kScratchRegister, Immediate(x));
261 } else if (is_uint32(x)) { 261 } else if (is_uint32(x)) {
262 movl(kScratchRegister, Immediate(x)); 262 movl(kScratchRegister, Immediate(x));
263 } else { 263 } else {
264 movq(kScratchRegister, x, RelocInfo::NONE); 264 movq(kScratchRegister, x, RelocInfo::NONE);
265 } 265 }
266 movq(dst, kScratchRegister); 266 movq(dst, kScratchRegister);
267 } 267 }
268 268
269 269
270 bool MacroAssembler::IsUnsafeSmi(Smi* value) {
271 return false;
272 }
273
274 void MacroAssembler::LoadUnsafeSmi(Register dst, Smi* source) {
275 UNIMPLEMENTED();
276 }
277
278
279 void MacroAssembler::Move(Register dst, Handle<Object> source) {
280 if (source->IsSmi()) {
281 if (IsUnsafeSmi(source)) {
282 LoadUnsafeSmi(dst, source);
283 } else {
284 movq(dst, source, RelocInfo::NONE);
285 }
286 } else {
287 movq(dst, source, RelocInfo::EMBEDDED_OBJECT);
288 }
289 }
290
291
292 void MacroAssembler::Move(const Operand& dst, Handle<Object> source) {
293 Move(kScratchRegister, source);
294 movq(dst, kScratchRegister);
295 }
296
297
298 void MacroAssembler::Cmp(Register dst, Handle<Object> source) {
299 Move(kScratchRegister, source);
300 cmpq(dst, kScratchRegister);
301 }
302
303
270 void MacroAssembler::Jump(ExternalReference ext) { 304 void MacroAssembler::Jump(ExternalReference ext) {
271 movq(kScratchRegister, ext); 305 movq(kScratchRegister, ext);
272 jmp(kScratchRegister); 306 jmp(kScratchRegister);
273 } 307 }
274 308
275 309
276 void MacroAssembler::Jump(Address destination, RelocInfo::Mode rmode) { 310 void MacroAssembler::Jump(Address destination, RelocInfo::Mode rmode) {
277 movq(kScratchRegister, destination, rmode); 311 movq(kScratchRegister, destination, rmode);
278 jmp(kScratchRegister); 312 jmp(kScratchRegister);
279 } 313 }
(...skipping 452 matching lines...) Expand 10 before | Expand all | Expand 10 after
732 push(rcx); 766 push(rcx);
733 767
734 // Clear the top frame. 768 // Clear the top frame.
735 ExternalReference c_entry_fp_address(Top::k_c_entry_fp_address); 769 ExternalReference c_entry_fp_address(Top::k_c_entry_fp_address);
736 movq(kScratchRegister, c_entry_fp_address); 770 movq(kScratchRegister, c_entry_fp_address);
737 movq(Operand(kScratchRegister, 0), Immediate(0)); 771 movq(Operand(kScratchRegister, 0), Immediate(0));
738 } 772 }
739 773
740 774
741 } } // namespace v8::internal 775 } } // namespace v8::internal
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698