develooper Front page | perl.perl5.changes | Postings from September 2021

[Perl/perl5] 0b2197: `make distclean` should delete`makedepend_file`

Nicholas Clark via perl5-changes
September 21, 2021 10:22
[Perl/perl5] 0b2197: `make distclean` should delete`makedepend_file`
Message ID:
  Branch: refs/heads/blead
  Commit: 0b2197e03b2b2b41b15ca3889712700c3b0cfcf5
  Author: Nicholas Clark <>
  Date:   2021-09-21 (Tue, 21 Sep 2021)

  Changed paths:
    M Makefile.SH

  Log Message:
  `make distclean` should delete `makedepend_file`

  Commit: 4b6b6165ecccd54b9fa91b2042c9655ef13dc6cc
  Author: Nicholas Clark <>
  Date:   2021-09-21 (Tue, 21 Sep 2021)

  Changed paths:
    M hv.c

  Log Message:
  In Perl_hv_iternext_flags() move a variable to a tighter scope

`xhv` was added to avoid repeated dereferences from the HV head in June 2001
as part of commit cbec93472053303a:
    Revert #10656 for performance reasons but leave in the
    use of Hv*() macros -- in comments, so that grepping the
    source is easier, from Abhijit.  (Also add the ENV_HV_NAME speedup
    suggested by Sarathy, also by Abhijit.)

Most uses were eliminated in May 2005 by commit bfcb351493b97935:
    Move hv_name, hv_eiter and hv_riter into a new aux structure.
    Provide (more efficient) _get and _set macros.
    Adjust the core to use them.

and commit 7b2c381cf37e4e46:
    Move the xpv_pv/xrv_rv member into the SV head, in a union with
    IV and UV. Avoid allocating a body for IVs and RVs.

The only other read of `xhv` was eliminated in June 2005 by commit
    Store the xhv_aux structure after the main array.
    This reduces the size of HV bodies from 24 to 20 bytes on a 32 bit
    build. It has the side effect of defined %symbol_table:: now always
    being true. defined %hash is already deprecated.

After that change xhv remained, saving the first deference, but it was
still dereferenced each time within a loop to read `xhv_max`.

Ideally that commit would have made this change - replace `xhv` with a
single lookup of HvMAX() in the scope where it is needed.

Compare: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About