equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2005, 2016, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2005, 2017, 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. |
712 GrowableArray<DepArgument>* args, |
712 GrowableArray<DepArgument>* args, |
713 Klass* witness) { |
713 Klass* witness) { |
714 if (xtty == NULL) { |
714 if (xtty == NULL) { |
715 return; |
715 return; |
716 } |
716 } |
717 ResourceMark rm; |
717 Thread* thread = Thread::current(); |
|
718 HandleMark rm(thread); |
718 ttyLocker ttyl; |
719 ttyLocker ttyl; |
719 int ctxkj = dep_context_arg(dept); // -1 if no context arg |
720 int ctxkj = dep_context_arg(dept); // -1 if no context arg |
720 if (witness != NULL) { |
721 if (witness != NULL) { |
721 xtty->begin_elem("dependency_failed"); |
722 xtty->begin_elem("dependency_failed"); |
722 } else { |
723 } else { |
730 for (int j = 0; j < args->length(); j++) { |
731 for (int j = 0; j < args->length(); j++) { |
731 if (j == ctxkj) continue; // already logged |
732 if (j == ctxkj) continue; // already logged |
732 DepArgument arg = args->at(j); |
733 DepArgument arg = args->at(j); |
733 if (j == 1) { |
734 if (j == 1) { |
734 if (arg.is_oop()) { |
735 if (arg.is_oop()) { |
735 xtty->object("x", arg.oop_value()); |
736 xtty->object("x", Handle(thread, arg.oop_value())); |
736 } else { |
737 } else { |
737 xtty->object("x", arg.metadata_value()); |
738 xtty->object("x", arg.metadata_value()); |
738 } |
739 } |
739 } else { |
740 } else { |
740 char xn[10]; sprintf(xn, "x%d", j); |
741 char xn[10]; sprintf(xn, "x%d", j); |
741 if (arg.is_oop()) { |
742 if (arg.is_oop()) { |
742 xtty->object(xn, arg.oop_value()); |
743 xtty->object(xn, Handle(thread, arg.oop_value())); |
743 } else { |
744 } else { |
744 xtty->object(xn, arg.metadata_value()); |
745 xtty->object(xn, arg.metadata_value()); |
745 } |
746 } |
746 } |
747 } |
747 } |
748 } |