This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug target/41473] [4.5 Regression] dsymutil "Assertion failed ..."



------- Comment #85 from howarth at nitro dot med dot uc dot edu  2009-11-26 22:35 -------
Created an attachment (id=19160)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=19160&action=view)
combined patch that fixes dsymutil asserts

Combined patches...

http://gcc.gnu.org/ml/gcc-patches/2009-11/msg01329.html
http://gcc.gnu.org/ml/gcc-patches/2009-11/msg01452.html

with hand merge of section...

@@ -15719,17 +15705,19 @@ add_location_or_const_value_attribute (d
      a constant value.  That way we are better to use
add_const_value_attribute
      rather than expanding constant value equivalent.  */
   loc_list = lookup_decl_loc (decl);
-  if (loc_list && loc_list->first && loc_list->first == loc_list->last)
+  if (loc_list && loc_list->first && loc_list->first == loc_list->last
+      && loc_list->first->var_loc_note
+      && NOTE_VAR_LOCATION (loc_list->first->var_loc_note)
+      && NOTE_VAR_LOCATION_LOC (loc_list->first->var_loc_note))
     {
       enum var_init_status status;
       struct var_loc_node *node;

       node = loc_list->first;
       status = NOTE_VAR_LOCATION_STATUS (node->var_loc_note);
-      rtl = NOTE_VAR_LOCATION (node->var_loc_note);
-      if (GET_CODE (rtl) == VAR_LOCATION
-         && GET_CODE (XEXP (rtl, 1)) != PARALLEL)
-       rtl = XEXP (XEXP (rtl, 1), 0);
+      rtl = NOTE_VAR_LOCATION_LOC (node->var_loc_note);
+      if (GET_CODE (rtl) != PARALLEL)
+       rtl = XEXP (rtl, 0);
       if ((CONSTANT_P (rtl) || GET_CODE (rtl) == CONST_STRING)
          && add_const_value_attribute (die, rtl))
         return true;

against current gcc trunk. This patch eliminates all of the asserts in dsymutil
during a bootstrap of gcc trunk.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41473


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]