Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-7018422

JavaAgent code always interpreted during initialization phase

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Not an Issue
    • Icon: P4 P4
    • 10
    • 7
    • hotspot
    • generic
    • generic

      The problem is due to the java agent being launched before the compiler is initialized. This results in all startup code for the agent will be executed by the interpreter only. Code registered by the agent will be compiled since those hooks will run later as well when the compiler has been started and therefore have the possiblility to be compiled and optimized.

      Talking with Tom and Vladimir it should be possible to move the java agent startup to after the compiler has been started to allow all code to be compiled.

      ---------------------
      Your agent is executed before Compiler threads are initialized
      during call to post_vm_initialized().

        // Notify JVMTI agents that VM initialization is complete - nop if no agents.
        JvmtiExport::post_vm_initialized();

        Chunk::start_chunk_pool_cleaner_task();

        // initialize compiler(s)
        CompileBroker::compilation_init();
      ---------------------

            Unassigned Unassigned
            sfriberg Staffan Friberg (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: