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

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

Issue 6639023: Merge revisions 7089, 7095, 7096 to trunk.... (Closed) Base URL: http://v8.googlecode.com/svn/trunk/
Patch Set: Created 9 years, 9 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/version.cc ('k') | src/x64/lithium-codegen-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 (c) 1994-2006 Sun Microsystems Inc. 1 // Copyright (c) 1994-2006 Sun Microsystems Inc.
2 // All Rights Reserved. 2 // All Rights Reserved.
3 // 3 //
4 // Redistribution and use in source and binary forms, with or without 4 // Redistribution and use in source and binary forms, with or without
5 // modification, are permitted provided that the following conditions are 5 // modification, are permitted provided that the following conditions are
6 // met: 6 // met:
7 // 7 //
8 // - Redistributions of source code must retain the above copyright notice, 8 // - Redistributions of source code must retain the above copyright notice,
9 // this list of conditions and the following disclaimer. 9 // this list of conditions and the following disclaimer.
10 // 10 //
(...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after
388 388
389 // Offset from existing memory operand. 389 // Offset from existing memory operand.
390 // Offset is added to existing displacement as 32-bit signed values and 390 // Offset is added to existing displacement as 32-bit signed values and
391 // this must not overflow. 391 // this must not overflow.
392 Operand(const Operand& base, int32_t offset); 392 Operand(const Operand& base, int32_t offset);
393 393
394 // Checks whether either base or index register is the given register. 394 // Checks whether either base or index register is the given register.
395 // Does not check the "reg" part of the Operand. 395 // Does not check the "reg" part of the Operand.
396 bool AddressUsesRegister(Register reg) const; 396 bool AddressUsesRegister(Register reg) const;
397 397
398 // Queries related to the size of the generated instruction.
399 // Whether the generated instruction will have a REX prefix.
400 bool requires_rex() const { return rex_ != 0; }
401 // Size of the ModR/M, SIB and displacement parts of the generated
402 // instruction.
403 int operand_size() const { return len_; }
404
398 private: 405 private:
399 byte rex_; 406 byte rex_;
400 byte buf_[6]; 407 byte buf_[6];
401 // The number of bytes of buf_ in use. 408 // The number of bytes of buf_ in use.
402 byte len_; 409 byte len_;
403 410
404 // Set the ModR/M byte without an encoded 'reg' register. The 411 // Set the ModR/M byte without an encoded 'reg' register. The
405 // register is encoded later as part of the emit_operand operation. 412 // register is encoded later as part of the emit_operand operation.
406 // set_modrm can be called before or after set_sib and set_disp*. 413 // set_modrm can be called before or after set_sib and set_disp*.
407 inline void set_modrm(int mod, Register rm); 414 inline void set_modrm(int mod, Register rm);
(...skipping 1167 matching lines...) Expand 10 before | Expand all | Expand 10 after
1575 private: 1582 private:
1576 Assembler* assembler_; 1583 Assembler* assembler_;
1577 #ifdef DEBUG 1584 #ifdef DEBUG
1578 int space_before_; 1585 int space_before_;
1579 #endif 1586 #endif
1580 }; 1587 };
1581 1588
1582 } } // namespace v8::internal 1589 } } // namespace v8::internal
1583 1590
1584 #endif // V8_X64_ASSEMBLER_X64_H_ 1591 #endif // V8_X64_ASSEMBLER_X64_H_
OLDNEW
« no previous file with comments | « src/version.cc ('k') | src/x64/lithium-codegen-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698