Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-22268

Enable gperftools on Linux s390x

    • Type: Icon: Improvement Improvement
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 3.3.5
    • Affects Version/s: None
    • Component/s: Portability
    • Labels:
      None
    • Fully Compatible
    • Platforms 13 (04/22/16)

      gperftools-2.2 can be built (at least the tcmalloc portion) on Linux s390x. These changes are not in upstream gperftools yet.

      1. gperftools does not have a stack unwinder for s390x. Add HAVE_DECL_BACKTRACE to CPPDEFINES.

      2. Define CACHELINE_ALIGNED in src/base/basictypes.h.

      3. Implement a cycle clock in src/base/cycleclock.h.

      4. Adapt src/base/linux_syscall_support.h for s390x.

      5. Fix a memcmp bug in src/base/sysinfo.cc, around line 124. This code assumes that both *p and name are at least namelen long, which is not always true.

      6. Implement do_mmap64 for s390x in src/malloc_hook_mmap_linux.h.

      With the above changes, MongoDB can be built without the --allocator=system option.

            Assignee:
            mark.benvenuto@mongodb.com Mark Benvenuto
            Reporter:
            bryanpkc Bryan Chan
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: