Mercurial > hg > truffle
comparison src/cpu/x86/vm/assembler_x86.hpp @ 4114:6729bbc1fcd6
7003454: order constants in constant table by number of references in code
Reviewed-by: kvn, never, bdelsart
author | twisti |
---|---|
date | Wed, 16 Nov 2011 01:39:50 -0800 |
parents | 95134e034042 |
children | 127b3692c168 |
comparison
equal
deleted
inserted
replaced
4113:8c57262447d3 | 4114:6729bbc1fcd6 |
---|---|
691 // Decoding | 691 // Decoding |
692 static address locate_operand(address inst, WhichOperand which); | 692 static address locate_operand(address inst, WhichOperand which); |
693 static address locate_next_instruction(address inst); | 693 static address locate_next_instruction(address inst); |
694 | 694 |
695 // Utilities | 695 // Utilities |
696 | |
697 #ifdef _LP64 | |
698 static bool is_simm(int64_t x, int nbits) { return -(CONST64(1) << (nbits-1)) <= x && | |
699 x < (CONST64(1) << (nbits-1)); } | |
700 static bool is_simm32(int64_t x) { return x == (int64_t)(int32_t)x; } | |
701 #else | |
702 static bool is_simm(int32_t x, int nbits) { return -(1 << (nbits-1)) <= x && | |
703 x < (1 << (nbits-1)); } | |
704 static bool is_simm32(int32_t x) { return true; } | |
705 #endif // _LP64 | |
706 | |
707 static bool is_polling_page_far() NOT_LP64({ return false;}); | 696 static bool is_polling_page_far() NOT_LP64({ return false;}); |
708 | 697 |
709 // Generic instructions | 698 // Generic instructions |
710 // Does 32bit or 64bit as needed for the platform. In some sense these | 699 // Does 32bit or 64bit as needed for the platform. In some sense these |
711 // belong in macro assembler but there is no need for both varieties to exist | 700 // belong in macro assembler but there is no need for both varieties to exist |