changeset 13573:1302b727b5cd

added assertion for correct format argument in a safepoint poll reloc info
author Doug Simon <doug.simon@oracle.com>
date Thu, 09 Jan 2014 08:30:58 +0100
parents 5335d65fec56
children 29db3f666f8d
files src/cpu/x86/vm/relocInfo_x86.cpp
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/cpu/x86/vm/relocInfo_x86.cpp	Thu Jan 09 08:29:54 2014 +0100
+++ b/src/cpu/x86/vm/relocInfo_x86.cpp	Thu Jan 09 08:30:58 2014 +0100
@@ -181,6 +181,9 @@
 #ifdef _LP64
   typedef Assembler::WhichOperand WhichOperand;
   WhichOperand which = (WhichOperand) format();
+#ifndef GRAAL
+  assert((which == Assembler::disp32_operand) == !Assembler::is_polling_page_far(), "format not set correctly");
+#endif
   if (which == Assembler::disp32_operand) {
     address orig_addr = old_addr_for(addr(), src, dest);
     NativeInstruction* oni = nativeInstruction_at(orig_addr);