emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Lexbind (was: Emacs 23.3 released)


From: Juanma Barranquero
Subject: Re: Lexbind (was: Emacs 23.3 released)
Date: Sat, 19 Mar 2011 01:54:43 +0100

On Thu, Mar 17, 2011 at 20:24, Eli Zaretskii <address@hidden> wrote:

> It would make sense to turn off bidi reordering and see if the hangs
> still happen.

Yes, it hangs with bidi turned off.

> Which means it loops inside try_scrolling.  Next step is to see where
> it loops there, and why it doesn't return.

It's looping here (in the else part, obviously):

      start_display (&it, w, startp);
      if (scroll_max < INT_MAX)
        move_it_vertically (&it, amount_to_scroll);
      else
        {
          /* Extra precision for users who set scroll-conservatively
             to most-positive-fixnum: make sure the amount we scroll
             the window start is never less than amount_to_scroll,
             which was computed as distance from window bottom to
             point.  This matters when lines at window top and lines
             below window bottom have different height.  */
          struct it it1 = it;
          /* We use a temporary it1 because line_bottom_y can modify
             its argument, if it moves one line down; see there.  */
          int start_y = line_bottom_y (&it1);

          do {
            move_it_by_lines (&it, 1, 1);
            it1 = it;
          } while (line_bottom_y (&it1) - start_y < amount_to_scroll);
        }

In my current session, line_bottom_y (&it1) == 15, start_y == 15,
amount_to_scroll == 15, forever and ever and ever.

    Juanma



(gdb) p it
$2 = {
  window = 55221765,
  w = 0x34a9e00,
  f = 0x343c800,
  method = GET_FROM_BUFFER,
  stop_charpos = 53,
  prev_stop = 0,
  base_level_stop = 0,
  end_charpos = 53,
  s = 0x0,
  string_nchars = 0,
  region_beg_charpos = -1,
  region_end_charpos = -1,
  redisplay_end_trigger_charpos = 0,
  multibyte_p = 1,
  header_line_p = 0,
  string_from_display_prop_p = 0,
  ellipsis_p = 0,
  avoid_cursor_p = 0,
  dp = 0x343cc00,
  dpvec = 0x0,
  dpend = 0x0,
  dpvec_char_len = 0,
  dpvec_face_id = 0,
  saved_face_id = 12,
  ctl_chars = {0 <repeats 16 times>},
  start = {
    pos = {
      charpos = 1,
      bytepos = 1
    },
    overlay_string_index = -1,
    string_pos = {
      charpos = -1,
      bytepos = -1
    },
    dpvec_index = -1
  },
  current = {
    pos = {
      charpos = 53,
      bytepos = 53
    },
    overlay_string_index = -1,
    string_pos = {
      charpos = -1,
      bytepos = -1
    },
    dpvec_index = -1
  },
  n_overlay_strings = 0,
  overlay_strings_charpos = 53,
  overlay_strings = {84671601, 0 <repeats 15 times>},
  string_overlays = {81053227, 0 <repeats 15 times>},
  string = 52250650,
  from_overlay = 0,
  stack = {{
      string = 52250650,
      string_nchars = 0,
      end_charpos = 53,
      stop_charpos = 2,
      prev_stop = 0,
      base_level_stop = 0,
      cmp_it = {
        stop_pos = 50,
        id = -1,
        ch = -2,
        rule_idx = 0,
        lookback = 0,
        nglyphs = 0,
        reversed_p = 0,
        charpos = 0,
        nchars = 0,
        nbytes = 0,
        from = 0,
        to = 0,
        width = 0
      },
      face_id = 12,
      u = {
        image = {
          object = 0,
          slice = {
            x = 0,
            y = 0,
            width = 0,
            height = 0
          },
          image_id = 0
        },
        comp = {
          object = 0
        },
        stretch = {
          object = 0
        }
      },
      position = {
        charpos = 1,
        bytepos = 1
      },
      current = {
        pos = {
          charpos = 1,
          bytepos = 1
        },
        overlay_string_index = 0,
        string_pos = {
          charpos = -1,
          bytepos = -1
        },
        dpvec_index = -1
      },
      from_overlay = 0,
      area = TEXT_AREA,
      method = GET_FROM_BUFFER,
      multibyte_p = 1,
      string_from_display_prop_p = 0,
      display_ellipsis_p = 0,
      avoid_cursor_p = 0,
      line_wrap = WINDOW_WRAP,
      voffset = 0,
      space_width = 52250650,
      font_height = 52250650
    }, {
      string = 0,
      string_nchars = 0,
      end_charpos = 0,
      stop_charpos = 0,
      prev_stop = 0,
      base_level_stop = 0,
      cmp_it = {
        stop_pos = 0,
        id = 0,
        ch = 0,
        rule_idx = 0,
        lookback = 0,
        nglyphs = 0,
        reversed_p = 0,
        charpos = 0,
        nchars = 0,
        nbytes = 0,
        from = 0,
        to = 0,
        width = 0
      },
      face_id = 0,
      u = {
        image = {
          object = 0,
          slice = {
            x = 0,
            y = 0,
            width = 0,
            height = 0
          },
          image_id = 0
        },
        comp = {
          object = 0
        },
        stretch = {
          object = 0
        }
      },
      position = {
        charpos = 0,
        bytepos = 0
      },
      current = {
        pos = {
          charpos = 0,
          bytepos = 0
        },
        overlay_string_index = 0,
        string_pos = {
          charpos = 0,
          bytepos = 0
        },
        dpvec_index = 0
      },
      from_overlay = 0,
      area = LEFT_MARGIN_AREA,
      method = GET_FROM_BUFFER,
      multibyte_p = 0,
      string_from_display_prop_p = 0,
      display_ellipsis_p = 0,
      avoid_cursor_p = 0,
      line_wrap = TRUNCATE,
      voffset = 0,
      space_width = 0,
      font_height = 0
    }, {
      string = 0,
      string_nchars = 0,
      end_charpos = 0,
      stop_charpos = 0,
      prev_stop = 0,
      base_level_stop = 0,
      cmp_it = {
        stop_pos = 0,
        id = 0,
        ch = 0,
        rule_idx = 0,
        lookback = 0,
        nglyphs = 0,
        reversed_p = 0,
        charpos = 0,
        nchars = 0,
        nbytes = 0,
        from = 0,
        to = 0,
        width = 0
      },
      face_id = 0,
      u = {
        image = {
          object = 0,
          slice = {
            x = 0,
            y = 0,
            width = 0,
            height = 0
          },
          image_id = 0
        },
        comp = {
          object = 0
        },
        stretch = {
          object = 0
        }
      },
      position = {
        charpos = 0,
        bytepos = 0
      },
      current = {
        pos = {
          charpos = 0,
          bytepos = 0
        },
        overlay_string_index = 0,
        string_pos = {
          charpos = 0,
          bytepos = 0
        },
        dpvec_index = 0
      },
      from_overlay = 0,
      area = LEFT_MARGIN_AREA,
      method = GET_FROM_BUFFER,
      multibyte_p = 0,
      string_from_display_prop_p = 0,
      display_ellipsis_p = 0,
      avoid_cursor_p = 0,
      line_wrap = TRUNCATE,
      voffset = 0,
      space_width = 0,
      font_height = 0
    }, {
      string = 0,
      string_nchars = 0,
      end_charpos = 0,
      stop_charpos = 0,
      prev_stop = 0,
      base_level_stop = 0,
      cmp_it = {
        stop_pos = 0,
        id = 0,
        ch = 0,
        rule_idx = 0,
        lookback = 0,
        nglyphs = 0,
        reversed_p = 0,
        charpos = 0,
        nchars = 0,
        nbytes = 0,
        from = 0,
        to = 0,
        width = 0
      },
      face_id = 0,
      u = {
        image = {
          object = 0,
          slice = {
            x = 0,
            y = 0,
            width = 0,
            height = 0
          },
          image_id = 0
        },
        comp = {
          object = 0
        },
        stretch = {
          object = 0
        }
      },
      position = {
        charpos = 0,
        bytepos = 0
      },
      current = {
        pos = {
          charpos = 0,
          bytepos = 0
        },
        overlay_string_index = 0,
        string_pos = {
          charpos = 0,
          bytepos = 0
        },
        dpvec_index = 0
      },
      from_overlay = 0,
      area = LEFT_MARGIN_AREA,
      method = GET_FROM_BUFFER,
      multibyte_p = 0,
      string_from_display_prop_p = 0,
      display_ellipsis_p = 0,
      avoid_cursor_p = 0,
      line_wrap = TRUNCATE,
      voffset = 0,
      space_width = 0,
      font_height = 0
    }, {
      string = 0,
      string_nchars = 0,
      end_charpos = 0,
      stop_charpos = 0,
      prev_stop = 0,
      base_level_stop = 0,
      cmp_it = {
        stop_pos = 0,
        id = 0,
        ch = 0,
        rule_idx = 0,
        lookback = 0,
        nglyphs = 0,
        reversed_p = 0,
        charpos = 0,
        nchars = 0,
        nbytes = 0,
        from = 0,
        to = 0,
        width = 0
      },
      face_id = 0,
      u = {
        image = {
          object = 0,
          slice = {
            x = 0,
            y = 0,
            width = 0,
            height = 0
          },
          image_id = 0
        },
        comp = {
          object = 0
        },
        stretch = {
          object = 0
        }
      },
      position = {
        charpos = 0,
        bytepos = 0
      },
      current = {
        pos = {
          charpos = 0,
          bytepos = 0
        },
        overlay_string_index = 0,
        string_pos = {
          charpos = 0,
          bytepos = 0
        },
        dpvec_index = 0
      },
      from_overlay = 0,
      area = LEFT_MARGIN_AREA,
      method = GET_FROM_BUFFER,
      multibyte_p = 0,
      string_from_display_prop_p = 0,
      display_ellipsis_p = 0,
      avoid_cursor_p = 0,
      line_wrap = TRUNCATE,
      voffset = 0,
      space_width = 0,
      font_height = 0
    }},
  sp = 0,
  selective = 0,
  what = IT_EOB,
  face_id = 0,
  selective_display_ellipsis_p = 1,
  ctl_arrow_p = 1,
  face_box_p = 0,
  start_of_box_run_p = 0,
  end_of_box_run_p = 0,
  overlay_strings_at_end_processed_p = 1,
  ignore_overlay_strings_at_pos_p = 0,
  glyph_not_available_p = 0,
  starts_in_middle_of_char_p = 0,
  face_before_selective_p = 0,
  constrain_row_ascent_descent_p = 0,
  line_wrap = WINDOW_WRAP,
  base_face_id = 0,
  c = 101,
  len = 1,
  cmp_it = {
    stop_pos = 50,
    id = -1,
    ch = -2,
    rule_idx = 0,
    lookback = 0,
    nglyphs = 0,
    reversed_p = 0,
    charpos = 0,
    nchars = 0,
    nbytes = 0,
    from = 0,
    to = 0,
    width = 0
  },
  char_to_display = 101,
  glyphless_method = GLYPHLESS_DISPLAY_THIN_SPACE,
  image_id = 0,
  slice = {
    x = 52250650,
    y = 52250650,
    width = 52250650,
    height = 52250650
  },
  space_width = 52250650,
  voffset = 0,
  tab_width = 8,
  font_height = 52250650,
  object = 80814597,
  position = {
    charpos = 53,
    bytepos = 53
  },
  truncation_pixel_width = 0,
  continuation_pixel_width = 0,
  first_visible_x = 0,
  last_visible_x = 928,
  last_visible_y = 15,
  extra_line_spacing = 0,
  max_extra_line_spacing = 0,
  override_ascent = -1,
  override_descent = 0,
  override_boff = 0,
  glyph_row = 0x4ce0800,
  area = TEXT_AREA,
  nglyphs = 1,
  pixel_width = 8,
  ascent = 12,
  descent = 3,
  max_ascent = 12,
  max_descent = 3,
  phys_ascent = 12,
  phys_descent = 3,
  max_phys_ascent = 12,
  max_phys_descent = 3,
  current_x = 432,
  continuation_lines_width = 0,
  eol_pos = {
    charpos = 0,
    bytepos = 0
  },
  current_y = 0,
  first_vpos = 0,
  vpos = 0,
  hpos = 54,
  left_user_fringe_bitmap = 0,
  right_user_fringe_bitmap = 0,
  left_user_fringe_face_id = 0,
  right_user_fringe_face_id = 0,
  bidi_p = 0,
  bidi_it = {
    bytepos = 0,
    charpos = 0,
    ch = 0,
    ch_len = 0,
    type = UNKNOWN_BT,
    type_after_w1 = UNKNOWN_BT,
    orig_type = UNKNOWN_BT,
    resolved_level = 0,
    invalid_levels = 0,
    invalid_rl_levels = 0,
    prev_was_pdf = 0,
    prev = {
      bytepos = 0,
      charpos = 0,
      type = UNKNOWN_BT,
      type_after_w1 = UNKNOWN_BT,
      orig_type = UNKNOWN_BT
    },
    last_strong = {
      bytepos = 0,
      charpos = 0,
      type = UNKNOWN_BT,
      type_after_w1 = UNKNOWN_BT,
      orig_type = UNKNOWN_BT
    },
    next_for_neutral = {
      bytepos = 0,
      charpos = 0,
      type = UNKNOWN_BT,
      type_after_w1 = UNKNOWN_BT,
      orig_type = UNKNOWN_BT
    },
    prev_for_neutral = {
      bytepos = 0,
      charpos = 0,
      type = UNKNOWN_BT,
      type_after_w1 = UNKNOWN_BT,
      orig_type = UNKNOWN_BT
    },
    next_for_ws = {
      bytepos = 0,
      charpos = 0,
      type = UNKNOWN_BT,
      type_after_w1 = UNKNOWN_BT,
      orig_type = UNKNOWN_BT
    },
    next_en_pos = 0,
    ignore_bn_limit = 0,
    sor = NEUTRAL_DIR,
    scan_dir = 0,
    stack_idx = 0,
    level_stack = {{
        level = 0,
        override = NEUTRAL_DIR
      } <repeats 64 times>},
    first_elt = 0,
    paragraph_dir = NEUTRAL_DIR,
    new_paragraph = 0,
    separator_limit = 0
  },
  paragraph_embedding = NEUTRAL_DIR
}
(gdb) n
13129               it1 = it;
(gdb) n
13130             } while (line_bottom_y (&it1) - start_y < amount_to_scroll);
(gdb) p start_y
$3 = 15
(gdb) p amount_to_scroll
$4 = 15
(gdb) p line_bottom_y (&it1)
$5 = 15
(gdb) n
13128               move_it_by_lines (&it, 1, 1);
(gdb)
13129               it1 = it;
(gdb)
13130             } while (line_bottom_y (&it1) - start_y < amount_to_scroll);
(gdb)
13128               move_it_by_lines (&it, 1, 1);
(gdb)
13129               it1 = it;
(gdb)
13130             } while (line_bottom_y (&it1) - start_y < amount_to_scroll);
(gdb) p line_bottom_y (&it1)
$6 = 15
(gdb)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]