1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-29 06:21:14 +02:00

StorePath: Rewrite in C++

On nix-env -qa -f '<nixpkgs>', this reduces maximum RSS by 20970 KiB
and runtime by 0.8%. This is mostly because we're not parsing the hash
part as a hash anymore (just validating that it consists of base-32
characters).

Also, replace storePathToHash() by StorePath::hashPart().
This commit is contained in:
Eelco Dolstra 2020-06-16 14:16:39 +02:00
parent 72e17290d4
commit 759947bf72
21 changed files with 110 additions and 111 deletions

View file

@ -7,5 +7,3 @@ libutil_DIR := $(d)
libutil_SOURCES := $(wildcard $(d)/*.cc)
libutil_LDFLAGS = $(LIBLZMA_LIBS) -lbz2 -pthread $(OPENSSL_LIBS) $(LIBBROTLI_LIBS) $(LIBARCHIVE_LIBS) $(BOOST_LDFLAGS) -lboost_context
libutil_LIBS = libnixrust

View file

@ -1,3 +1,4 @@
#if 0
#include "logging.hh"
#include "rust-ffi.hh"
@ -20,3 +21,4 @@ std::ostream & operator << (std::ostream & str, const String & s)
}
}
#endif

View file

@ -1,4 +1,5 @@
#pragma once
#if 0
#include "serialise.hh"
@ -185,3 +186,4 @@ struct Result
};
}
#endif