Skip to content

Is cached_digest doing extra work on cmt files? #4273

@ejgallego

Description

@ejgallego

Dear dune devs,

I have been observing some re-hashing of files on what should be a no-op rebuild, example from the Coq sources after doing dune build coq.install after a previous full build:

[dirty / mtime] _build/install/default/lib/coq/vernac/vernacextend.cmt {old: 1613989865.805196/ new: 1613990621.966763}
[dirty / perm ] _build/install/default/lib/coq/vernac/vernacextend.cmt {old: 292/ new: 511}
[dirty / size ] _build/install/default/lib/coq/vernac/vernacextend.cmt {old: 112027/ new: 64}
[dirty / mtime] _build/install/default/lib/coq/vernac/vernacextend.cmti {old: 1613989865.479193/ new: 1613990621.967763}
[dirty / perm ] _build/install/default/lib/coq/vernac/vernacextend.cmti {old: 292/ new: 511}
[dirty / size ] _build/install/default/lib/coq/vernac/vernacextend.cmti {old: 40355/ new: 65}

so indeed, all .cmt{,i} files in the source tree seem to be re-digested, however it seems to me they should not. After the digest, nothing is rebuilt, I guess the digest matches the stored one, tho cmt tend to be leaves themselves.

  • dune version: master
  • OCaml version: 4.12.0-rc1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions