Index: linkers/rtems-exeinfo.cpp
===================================================================
--- linkers/rtems-exeinfo.cpp	(revision f86a0cec854286d9e26465fc9c364bb96c12a969)
+++ linkers/rtems-exeinfo.cpp	(revision 463831374ce73e6792c6fc6c02e705cf3b8fc349)
@@ -154,5 +154,5 @@
        * Check the compiler and flags match.
        */
-      void output_compilation_unit (bool objects);
+      void output_compilation_unit (bool objects, bool full_flags);
 
       /*
@@ -177,4 +177,9 @@
 
       /*
+       * Output the configuration.
+       */
+      void output_config ();
+
+      /*
        * Output the TLS data.
        */
@@ -190,4 +195,8 @@
        */
       void output_dwarf ();
+
+    private:
+
+      void config (const std::string name);
     };
 
@@ -310,4 +319,5 @@
       debug.load_debug ();
       debug.load_types ();
+      debug.load_variables ();
       debug.load_functions ();
       symbols.globals (addresses);
@@ -322,5 +332,5 @@
 
     void
-    image::output_compilation_unit (bool objects)
+    image::output_compilation_unit (bool objects, bool full_flags)
     {
       dwarf::compilation_units& cus = debug.get_cus ();
@@ -475,10 +485,13 @@
               {
                 bool present = false;
-                for (auto& ff : filter_flags)
+                if (!full_flags)
                 {
-                  if (rld::starts_with(f, ff))
+                  for (auto& ff : filter_flags)
                   {
-                    present = true;
-                    break;
+                    if (rld::starts_with(f, ff))
+                    {
+                      present = true;
+                      break;
+                    }
                   }
                 }
@@ -628,4 +641,5 @@
       symbols::symbol* tls_size = symbols.find_global("_TLS_Size");
       symbols::symbol* tls_alignment = symbols.find_global("_TLS_Alignment");
+      symbols::symbol* tls_max_size = symbols.find_global("_Thread_Maximum_TLS_size");
 
       if (tls_data_begin == nullptr ||
@@ -651,27 +665,30 @@
         }
         std::cout << "TLS environment is INVALID (please report):" << std::endl
-                  << " _TLS_Data_begin : "
+                  << " _TLS_Data_begin          : "
                   << (char*) (tls_data_begin == nullptr ? "not-found" : "found")
                   << std::endl
-                  << " _TLS_Data_end   : "
+                  << " _TLS_Data_end            : "
                   << (char*) (tls_data_end == nullptr ? "not-found" : "found")
                   << std::endl
-                  << " _TLS_Data_size  : "
+                  << " _TLS_Data_size           : "
                   << (char*) (tls_data_size == nullptr ? "not-found" : "found")
                   << std::endl
-                  << " _TLS_BSS_begin  : "
+                  << " _TLS_BSS_begin           : "
                   << (char*) (tls_bss_begin == nullptr ? "not-found" : "found")
                   << std::endl
-                  << " _TLS_BSS_end    : "
+                  << " _TLS_BSS_end             : "
                   << (char*) (tls_bss_end == nullptr ? "not-found" : "found")
                   << std::endl
-                  << " _TLS_BSS_Size   : "
+                  << " _TLS_BSS_Size            : "
                   << (char*) (tls_bss_size == nullptr ? "not-found" : "found")
                   << std::endl
-                  << " _TLS_Size       : "
+                  << " _TLS_Size                : "
                   << (char*) (tls_size == nullptr ? "not-found" : "found")
                   << std::endl
-                  << " _TLS_Alignment  : "
+                  << " _TLS_Alignment           : "
                   << (char*) (tls_alignment == nullptr ? "not-found" : "found")
+                  << std::endl
+                  << " _Thread_Maximum_TLS_size : "
+                  << (char*) (tls_max_size == nullptr ? "not-found" : "found")
                   << std::endl
                   << std::endl;
@@ -680,5 +697,10 @@
 
       std::cout << "TLS size      : " << tls_size->value () << std::endl
-                << "    data size : " << tls_data_size->value () << std::endl
+                << "     max size : ";
+      if (tls_max_size == nullptr)
+          std::cout << "not found" << std::endl;
+      else
+          std::cout << tls_max_size->value () << std::endl;
+      std::cout << "    data size : " << tls_data_size->value () << std::endl
                 << "     bss size : " << tls_bss_size->value () << std::endl
                 << "    alignment : " << tls_alignment->value () << std::endl
@@ -688,4 +710,29 @@
                 << std::dec << std::setfill (' ')
                 << std::endl;
+    }
+
+    void image::config(const std::string name)
+    {
+      std::string table_name = "_" + name + "_Information";
+      symbols::symbol* table = symbols.find_global(table_name);
+
+      if (table != nullptr)
+        std::cout << " " << name << std::endl;
+    }
+
+    void image::output_config()
+    {
+      std::cout << "Configurations:" << std::endl;
+      config("Thread");
+      config("Barrier");
+      config("Extension");
+      config("Message_queue");
+      config("Partition");
+      config("Rate_monotonic");
+      config("Dual_ported_memory");
+      config("Region");
+      config("Semaphore");
+      config("Timer");
+      config("RTEMS_tasks");
     }
 
@@ -836,4 +883,6 @@
   { "fini",        no_argument,            NULL,           'F' },
   { "objects",     no_argument,            NULL,           'O' },
+  { "full-flags",  no_argument,            NULL,           'A' },
+  { "config",      no_argument,            NULL,           'C' },
   { "tls",         no_argument,            NULL,           'T' },
   { "inlined",     no_argument,            NULL,           'i' },
@@ -857,4 +906,6 @@
             << " -F        : show fini section tables (also --fini)" << std::endl
             << " -O        : show object files (also --objects)" << std::endl
+            << "           :  add --full-flags for compiler options" << std::endl
+            << " -C        : show configuration (also --config)" << std::endl
             << " -T        : show thread local storage data (also --tls)" << std::endl
             << " -i        : show inlined code (also --inlined)" << std::endl
@@ -922,4 +973,6 @@
     bool        fini = false;
     bool        objects = false;
+    bool        full_flags = false;
+    bool        config = false;
     bool        tls = false;
     bool        inlined = false;
@@ -930,5 +983,5 @@
     while (true)
     {
-      int opt = ::getopt_long (argc, argv, "hvVMaSIFOTiD", rld_opts, NULL);
+      int opt = ::getopt_long (argc, argv, "hvVMaSIFOCTiD", rld_opts, NULL);
       if (opt < 0)
         break;
@@ -971,4 +1024,12 @@
           break;
 
+        case 'A':
+          full_flags = true;
+          break;
+
+        case 'C':
+          config = true;
+          break;
+
         case 'T':
           tls = true;
@@ -1013,4 +1074,5 @@
       fini = true;
       objects = true;
+      config = true;
       tls = true;
       inlined = true;
@@ -1044,5 +1106,5 @@
      * Generate the output.
      */
-    exe.output_compilation_unit (objects);
+    exe.output_compilation_unit (objects, full_flags);
     if (sections)
       exe.output_sections ();
@@ -1051,4 +1113,6 @@
     if (fini)
       exe.output_fini ();
+    if (config)
+      exe.output_config ();
     if (tls)
       exe.output_tls ();
Index: rtemstoolkit/rld-dwarf.cpp
===================================================================
--- rtemstoolkit/rld-dwarf.cpp	(revision f86a0cec854286d9e26465fc9c364bb96c12a969)
+++ rtemstoolkit/rld-dwarf.cpp	(revision 463831374ce73e6792c6fc6c02e705cf3b8fc349)
@@ -574,4 +574,102 @@
       }
       return *this;
+    }
+
+    variable::variable (file& debug, debug_info_entry& die)
+      : debug (debug),
+        external_ (false),
+        declaration_ (false)
+    {
+      dwarf_bool db;
+
+      if (die.attribute (DW_AT_external, db, false))
+        external_ = db ? true : false;
+
+      if (die.attribute (DW_AT_declaration, db, false))
+        declaration_ = db ? true : false;
+
+      /*
+       * Get the name attribute. (if present)
+       */
+      die.attribute (DW_AT_name, name_);
+      die.attribute (DW_AT_decl_file, decl_file_);
+      die.attribute (DW_AT_decl_line, decl_line_);
+
+      if (rld::verbose () >= RLD_VERBOSE_FULL_DEBUG)
+      {
+        std::cout << "dwarf::variable: ";
+        dump (std::cout);
+        std::cout << std::endl;
+      }
+    }
+
+    variable::variable (const variable& orig)
+      : debug (orig.debug),
+        external_ (orig.external_),
+        declaration_ (orig.declaration_),
+        name_ (orig.name_),
+        decl_file_ (orig.decl_file_),
+        decl_line_ (orig. decl_line_)
+    {
+    }
+
+    variable::~variable ()
+    {
+    }
+
+    std::string
+    variable::name () const
+    {
+      return name_;
+    }
+
+    bool
+    variable::is_external () const
+    {
+      return external_;
+    }
+
+    bool
+    variable::is_declaration () const
+    {
+      return declaration_;
+    }
+
+    size_t
+    variable::size () const
+    {
+      size_t s = 0;
+      return s;
+    }
+
+    variable&
+    variable::operator = (const variable& rhs)
+    {
+      if (this != &rhs)
+      {
+        debug = rhs.debug;
+        external_ = rhs.external_;
+        declaration_ = rhs.declaration_;
+        name_ = rhs.name_;
+        decl_file_ = rhs.decl_file_;
+        decl_line_ = rhs.decl_line_;
+      }
+      return *this;
+    }
+
+    void
+    variable::dump (std::ostream& out) const
+    {
+      if (name_.empty ())
+        out << "NO-NAME";
+      else
+        out << name_;
+      out << " ["
+          << (char) (external_ ? 'E' : '-')
+          << (char) (declaration_ ? 'D' : '-')
+          << "] size=" << size ()
+          << std::hex << std::setfill ('0')
+          << " (0x" << size () << ')'
+          << std::dec << std::setfill (' ');
     }
 
@@ -1514,5 +1612,4 @@
     {
       die.attribute (DW_AT_name, name_);
-      name_ = name_;
 
       die.attribute (DW_AT_producer, producer_);
@@ -1675,4 +1772,36 @@
 
     void
+    compilation_unit::load_variables ()
+    {
+      debug_info_entry die (debug, die_offset);
+      debug_info_entry child (debug);
+      if (die.get_child (child))
+        load_variables (child);
+    }
+
+    void
+    compilation_unit::load_variables (debug_info_entry& die)
+    {
+      while (true)
+      {
+        if (die.tag () == DW_TAG_variable)
+        {
+          function func (debug, die);
+          functions_.push_back (func);
+        }
+
+        debug_info_entry next (die.get_debug ());
+
+        if (die.get_child (next))
+          load_functions (next);
+
+        if (!die.get_sibling (next))
+          break;
+
+        die = next;
+      }
+    }
+
+    void
     compilation_unit::load_functions ()
     {
@@ -1994,4 +2123,11 @@
 
     void
+    file::load_variables ()
+    {
+      for (auto& cu : cus)
+        cu.load_variables ();
+    }
+
+    void
     file::load_functions ()
     {
Index: rtemstoolkit/rld-dwarf.h
===================================================================
--- rtemstoolkit/rld-dwarf.h	(revision f86a0cec854286d9e26465fc9c364bb96c12a969)
+++ rtemstoolkit/rld-dwarf.h	(revision 463831374ce73e6792c6fc6c02e705cf3b8fc349)
@@ -278,4 +278,57 @@
 
     /**
+     * Variable.
+     */
+    class variable
+    {
+    public:
+
+      variable (file& debug, debug_info_entry& die);
+      variable (const variable& orig);
+      ~variable ();
+
+      /**
+       * Get the name of the variable.
+       */
+      std::string name () const;
+
+      /**
+       * Is the variable external?
+       */
+      bool is_external () const;
+
+      /**
+       * Is this just a declaration?
+       */
+      bool is_declaration () const;
+
+      /**
+       * Size of the variable.
+       */
+      size_t size () const;
+
+      /**
+       * Assigment operator.
+       */
+      variable& operator = (const variable& rhs);
+
+      /**
+       * Dump the variable.
+       */
+      void dump (std::ostream& out) const;
+
+    private:
+
+      file&          debug;
+      bool           external_;
+      bool           declaration_;
+      std::string    name_;
+      std::string    decl_file_;
+      dwarf_unsigned decl_line_;
+    };
+
+    typedef std::vector < variable > variables;
+
+    /**
      * Function.
      */
@@ -621,4 +674,9 @@
 
       /**
+       * Load the variables.
+       */
+      void load_variables ();
+
+      /**
        * Load the functions.
        */
@@ -678,4 +736,5 @@
     private:
 
+      void load_variables (debug_info_entry& die);
       void load_functions (debug_info_entry& die);
 
@@ -782,4 +841,9 @@
 
       /**
+       * Load the DWARF variables information.
+       */
+      void load_variables ();
+
+      /**
        * Get the source location given an address.
        */
@@ -794,4 +858,9 @@
 
       /**
+       * Get the variable given a name. Raises an exception if not found.
+       */
+      variable& get_variable (std::string& name);
+
+      /**
        * Does the function exist.
        */
