comparison src/share/vm/compiler/oopMap.cpp @ 17937:78bbf4d43a14

8037816: Fix for 8036122 breaks build with Xcode5/clang 8043029: Change 8037816 breaks HS build with older GCC versions which don't support diagnostic pragmas 8043164: Format warning in traceStream.hpp Summary: Backport of main fix + two corrections, enables clang compilation, turns on format attributes, corrects/mutes warnings Reviewed-by: kvn, coleenp, iveresov, twisti
author drchase
date Thu, 22 May 2014 15:52:41 -0400
parents 190899198332
children 52b4284cb496 6ad19ab94176
comparison
equal deleted inserted replaced
17935:7384f6a12fc1 17937:78bbf4d43a14
1 /* 1 /*
2 * Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 1998, 2014, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 * 4 *
5 * This code is free software; you can redistribute it and/or modify it 5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as 6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
644 644
645 if (TraceDerivedPointers) { 645 if (TraceDerivedPointers) {
646 tty->print_cr( 646 tty->print_cr(
647 "Add derived pointer@" INTPTR_FORMAT 647 "Add derived pointer@" INTPTR_FORMAT
648 " - Derived: " INTPTR_FORMAT 648 " - Derived: " INTPTR_FORMAT
649 " Base: " INTPTR_FORMAT " (@" INTPTR_FORMAT ") (Offset: %d)", 649 " Base: " INTPTR_FORMAT " (@" INTPTR_FORMAT ") (Offset: " INTX_FORMAT ")",
650 derived_loc, (address)*derived_loc, (address)*base_loc, base_loc, offset 650 p2i(derived_loc), p2i((address)*derived_loc), p2i((address)*base_loc), p2i(base_loc), offset
651 ); 651 );
652 } 652 }
653 // Set derived oop location to point to base. 653 // Set derived oop location to point to base.
654 *derived_loc = (oop)base_loc; 654 *derived_loc = (oop)base_loc;
655 assert_lock_strong(DerivedPointerTableGC_lock); 655 assert_lock_strong(DerivedPointerTableGC_lock);
672 *derived_loc = (oop)(((address)base) + offset); 672 *derived_loc = (oop)(((address)base) + offset);
673 assert(value_of_loc(derived_loc) - value_of_loc(&base) == offset, "sanity check"); 673 assert(value_of_loc(derived_loc) - value_of_loc(&base) == offset, "sanity check");
674 674
675 if (TraceDerivedPointers) { 675 if (TraceDerivedPointers) {
676 tty->print_cr("Updating derived pointer@" INTPTR_FORMAT 676 tty->print_cr("Updating derived pointer@" INTPTR_FORMAT
677 " - Derived: " INTPTR_FORMAT " Base: " INTPTR_FORMAT " (Offset: %d)", 677 " - Derived: " INTPTR_FORMAT " Base: " INTPTR_FORMAT " (Offset: " INTX_FORMAT ")",
678 derived_loc, (address)*derived_loc, (address)base, offset); 678 p2i(derived_loc), p2i((address)*derived_loc), p2i((address)base), offset);
679 } 679 }
680 680
681 // Delete entry 681 // Delete entry
682 delete entry; 682 delete entry;
683 _list->at_put(i, NULL); 683 _list->at_put(i, NULL);