[OpenSIPS-Devel] [OpenSIPS/opensips] 6ecd6b: shm: Remove unused/deprecated functions

Liviu Chircu noreply at github.com
Mon May 27 11:33:25 EDT 2019


  Branch: refs/heads/master
  Home:   https://github.com/OpenSIPS/opensips
  Commit: 6ecd6bfbb2c50ac1c2a78e160e80709b9deb7063
      https://github.com/OpenSIPS/opensips/commit/6ecd6bfbb2c50ac1c2a78e160e80709b9deb7063
  Author: Liviu Chircu <liviu at opensips.org>
  Date:   2019-05-27 (Mon, 27 May 2019)

  Changed paths:
    M mem/shm_mem.c

  Log Message:
  -----------
  shm: Remove unused/deprecated functions


  Commit: 4bd078f11be38534a32aa66e65c931dbd386c607
      https://github.com/OpenSIPS/opensips/commit/4bd078f11be38534a32aa66e65c931dbd386c607
  Author: Liviu Chircu <liviu at opensips.org>
  Date:   2019-05-27 (Mon, 27 May 2019)

  Changed paths:
    M mem/rpm_mem.h

  Log Message:
  -----------
  rpm memory: Fix rpm_free() locking

    * fix "shm_unlock()" copy-paste error
    * the ifdefs are unnecessary, as the rpm_lock/unlock macros do
      exactly that


  Commit: 24b0735076c20464f22047201674f78d184d72e0
      https://github.com/OpenSIPS/opensips/commit/24b0735076c20464f22047201674f78d184d72e0
  Author: Liviu Chircu <liviu at opensips.org>
  Date:   2019-05-27 (Mon, 27 May 2019)

  Changed paths:
    M mem/shm_mem.h

  Log Message:
  -----------
  shared memory: Fix unsafe shm_free() when debugging

When HP_MALLOC was included in the build, the F_MALLOC_DBG and
Q_MALLOC_DBG allocators were broken, since their shm_free() operation
was purely lockless and could corrupt the memory at any time.


  Commit: 3a921cc3744408bea05fc49a85da8e337df6d2d3
      https://github.com/OpenSIPS/opensips/commit/3a921cc3744408bea05fc49a85da8e337df6d2d3
  Author: Liviu Chircu <liviu at opensips.org>
  Date:   2019-05-27 (Mon, 27 May 2019)

  Changed paths:
    M mem/shm_mem.h

  Log Message:
  -----------
  shared memory: Add support for bulk operations

This patch adds the following functions:
    * shm_malloc_bulk()
    * shm_free_bulk()

Their purpose is to minimize contention, in situations where the
developer needs to perform lots of consecutive shared memory operations.
In this case, their usage is as follows:

shm_lock();
shm_malloc_bulk();
shm_malloc_bulk();
...
shm_free_bulk(...);
shm_malloc_bulk();
shm_free_bulk(...);
...
shm_unlock();


  Commit: 216bf4df007b2b2fbba43d9a292cad1982691c35
      https://github.com/OpenSIPS/opensips/commit/216bf4df007b2b2fbba43d9a292cad1982691c35
  Author: Liviu Chircu <liviu at opensips.org>
  Date:   2019-05-27 (Mon, 27 May 2019)

  Changed paths:
    M modules/tm/h_table.c
    M modules/tm/sip_msg.c
    M modules/tm/sip_msg.h
    M modules/tm/t_reply.c
    M usr_avp.c
    M usr_avp.h

  Log Message:
  -----------
  tm: Refactor code to use bulk shm operations


Compare: https://github.com/OpenSIPS/opensips/compare/1880111a33be...216bf4df007b



More information about the Devel mailing list