src/hotspot/share/runtime/arguments.hpp
branchepsilon-gc-branch
changeset 56021 864ee22719af
parent 55974 06122633fead
parent 48474 6e69aea2aee7
child 56276 ee5e58456be5
equal deleted inserted replaced
55980:67d289ae67f5 56021:864ee22719af
   140   char*           _name;
   140   char*           _name;
   141   char*           _options;
   141   char*           _options;
   142   void*           _os_lib;
   142   void*           _os_lib;
   143   bool            _is_absolute_path;
   143   bool            _is_absolute_path;
   144   bool            _is_static_lib;
   144   bool            _is_static_lib;
       
   145   bool            _is_instrument_lib;
   145   AgentState      _state;
   146   AgentState      _state;
   146   AgentLibrary*   _next;
   147   AgentLibrary*   _next;
   147 
   148 
   148  public:
   149  public:
   149   // Accessors
   150   // Accessors
   152   bool is_absolute_path() const             { return _is_absolute_path; }
   153   bool is_absolute_path() const             { return _is_absolute_path; }
   153   void* os_lib() const                      { return _os_lib; }
   154   void* os_lib() const                      { return _os_lib; }
   154   void set_os_lib(void* os_lib)             { _os_lib = os_lib; }
   155   void set_os_lib(void* os_lib)             { _os_lib = os_lib; }
   155   AgentLibrary* next() const                { return _next; }
   156   AgentLibrary* next() const                { return _next; }
   156   bool is_static_lib() const                { return _is_static_lib; }
   157   bool is_static_lib() const                { return _is_static_lib; }
       
   158   bool is_instrument_lib() const            { return _is_instrument_lib; }
   157   void set_static_lib(bool is_static_lib)   { _is_static_lib = is_static_lib; }
   159   void set_static_lib(bool is_static_lib)   { _is_static_lib = is_static_lib; }
   158   bool valid()                              { return (_state == agent_valid); }
   160   bool valid()                              { return (_state == agent_valid); }
   159   void set_valid()                          { _state = agent_valid; }
   161   void set_valid()                          { _state = agent_valid; }
   160   void set_invalid()                        { _state = agent_invalid; }
   162   void set_invalid()                        { _state = agent_invalid; }
   161 
   163 
   162   // Constructor
   164   // Constructor
   163   AgentLibrary(const char* name, const char* options, bool is_absolute_path, void* os_lib);
   165   AgentLibrary(const char* name, const char* options, bool is_absolute_path,
       
   166                void* os_lib, bool instrument_lib=false);
   164 };
   167 };
   165 
   168 
   166 // maintain an order of entry list of AgentLibrary
   169 // maintain an order of entry list of AgentLibrary
   167 class AgentLibraryList VALUE_OBJ_CLASS_SPEC {
   170 class AgentLibraryList VALUE_OBJ_CLASS_SPEC {
   168  private:
   171  private:
   335   static void add_init_library(const char* name, char* options);
   338   static void add_init_library(const char* name, char* options);
   336 
   339 
   337   // -agentlib and -agentpath arguments
   340   // -agentlib and -agentpath arguments
   338   static AgentLibraryList _agentList;
   341   static AgentLibraryList _agentList;
   339   static void add_init_agent(const char* name, char* options, bool absolute_path);
   342   static void add_init_agent(const char* name, char* options, bool absolute_path);
       
   343   static void add_instrument_agent(const char* name, char* options, bool absolute_path);
   340 
   344 
   341   // Late-binding agents not started via arguments
   345   // Late-binding agents not started via arguments
   342   static void add_loaded_agent(AgentLibrary *agentLib);
   346   static void add_loaded_agent(AgentLibrary *agentLib);
   343   static void add_loaded_agent(const char* name, char* options, bool absolute_path, void* os_lib);
   347   static void add_loaded_agent(const char* name, char* options, bool absolute_path, void* os_lib);
   344 
   348