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

do memcmp before memcpy for update?

    • Type: Icon: Improvement Improvement
    • Resolution: Won't Fix
    • Priority: Icon: Minor - P4 Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None

      should we compare the old and new objects an update before writing?

      what i'm thinking is that if we're writing the same object out - it may incur a dirty bit set on the page when it doesn't need to be.
      which could lead to more disk activity.

      we'll already have to read the page in - so its just the comparison that we add. and we only have to do it if they are exactly the same size. my guess is if the object changes - most of the time the size will change anyway.

            Assignee:
            dwight@mongodb.com Dwight Merriman
            Reporter:
            eliot Eliot Horowitz (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: