772 task->mark_on_stack();
773 task = task->next();
774 }
775 }
776
777
778 CompileQueue* CompileBroker::compile_queue(int comp_level) {
779 if (is_c2_compile(comp_level)) return _c2_compile_queue;
780 if (is_c1_compile(comp_level)) return _c1_compile_queue;
781 return NULL;
782 }
783
784
785 void CompileBroker::print_compile_queues(outputStream* st) {
786 _c1_compile_queue->print(st);
787 _c2_compile_queue->print(st);
788 }
789
790
791 void CompileQueue::print(outputStream* st) {
792 assert_locked_or_safepoint(lock());
793 st->print_cr("Contents of %s", name());
794 st->print_cr("----------------------------");
795 CompileTask* task = _first;
796 if (task == NULL) {
797 st->print_cr("Empty");;
798 } else {
799 while (task != NULL) {
800 task->print_compilation(st, NULL, true, true);
801 task = task->next();
802 }
803 }
804 st->print_cr("----------------------------");
805 }
806
807 void CompileQueue::print_tty() {
808 ttyLocker ttyl;
809 print(tty);
810 }
811
812 CompilerCounters::CompilerCounters(const char* thread_name, int instance, TRAPS) {
813
814 _current_method[0] = '\0';
815 _compile_type = CompileBroker::no_compile;
816
817 if (UsePerfData) {
|
772 task->mark_on_stack();
773 task = task->next();
774 }
775 }
776
777
778 CompileQueue* CompileBroker::compile_queue(int comp_level) {
779 if (is_c2_compile(comp_level)) return _c2_compile_queue;
780 if (is_c1_compile(comp_level)) return _c1_compile_queue;
781 return NULL;
782 }
783
784
785 void CompileBroker::print_compile_queues(outputStream* st) {
786 _c1_compile_queue->print(st);
787 _c2_compile_queue->print(st);
788 }
789
790
791 void CompileQueue::print(outputStream* st) {
792 MutexLocker locker(lock());
793 st->print_cr("Contents of %s", name());
794 st->print_cr("----------------------------");
795 CompileTask* task = _first;
796 if (task == NULL) {
797 st->print_cr("Empty");
798 } else {
799 while (task != NULL) {
800 task->print_compilation(st, NULL, true, true);
801 task = task->next();
802 }
803 }
804 st->print_cr("----------------------------");
805 }
806
807 void CompileQueue::print_tty() {
808 ttyLocker ttyl;
809 print(tty);
810 }
811
812 CompilerCounters::CompilerCounters(const char* thread_name, int instance, TRAPS) {
813
814 _current_method[0] = '\0';
815 _compile_type = CompileBroker::no_compile;
816
817 if (UsePerfData) {
|