[SERVER-31380] Add metrics related to tcmalloc acquiring and decommitting memory from system Created: 04/Oct/17  Updated: 30/Oct/23  Resolved: 03/Nov/17

Status: Closed
Project: Core Server
Component/s: Diagnostics, Internal Code
Affects Version/s: None
Fix Version/s: 3.2.19, 3.4.11, 3.6.0-rc3

Type: Improvement Priority: Major - P3
Reporter: Bruce Lucas (Inactive) Assignee: Mark Benvenuto
Resolution: Fixed Votes: 20
Labels: SWDI
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Related
is related to SERVER-31417 Improve tcmalloc when decommitting la... Backlog
Backwards Compatibility: Fully Compatible
Backport Requested:
v3.4, v3.2
Sprint: Platforms 2017-11-13
Participants:

 Description   

From time to time tcmalloc acquires memory from the system using mmap, and returns it to the system using madvise. These can be expensive operations, and they hold a lock so they can create a bottleneck. There aren't adequate metrics to diagnose issues related to this, and to assess the effect of making changes such as enabling TCMALLOC_AGGRESSIVE_DECOMMIT. The following could be helpful:

  • number of mmap operations to acquire memory
  • number of bytes acquired
  • cumulative time spent in such operations
  • number of madvise oeprations to release memory
  • number of bytes released
  • cumulative time spent in such operations
  • number of bytes allocated using decommitted memory (which kernel then must re-commit)


 Comments   
Comment by Githook User [ 08/Dec/17 ]

Author:

{'name': 'Mark Benvenuto', 'email': 'mark.benvenuto@mongodb.com', 'username': 'markbenvenuto'}

Message: SERVER-31380 Add metrics related to tcmalloc acquiring and decommitting memory from system

(cherry picked from commit acfa4b77e4c03dc73b54baedae652478e43740a5)
Branch: v3.2
https://github.com/mongodb/mongo/commit/f34fbd1a04dc2bc99057a2fb2f47ea097d11b746

Comment by Githook User [ 04/Dec/17 ]

Author:

{'username': 'markbenvenuto', 'email': 'mark.benvenuto@mongodb.com', 'name': 'Mark Benvenuto'}

Message: SERVER-31380 Add metrics related to tcmalloc acquiring and decommitting memory from system

(cherry picked from commit acfa4b77e4c03dc73b54baedae652478e43740a5)
Branch: v3.4
https://github.com/mongodb/mongo/commit/6188e0cadfd30ee7961ecbb7d7ba5721a826cc9d

Comment by Githook User [ 03/Nov/17 ]

Author:

{'name': 'Mark Benvenuto', 'username': 'markbenvenuto', 'email': 'mark.benvenuto@mongodb.com'}

Message: SERVER-31380 Add metrics related to tcmalloc acquiring and decommitting memory from system
Branch: master
https://github.com/mongodb/mongo/commit/acfa4b77e4c03dc73b54baedae652478e43740a5

Generated at Thu Feb 08 04:26:51 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.