From 2dc6d5094183edee523a48d449eab1a376e839a2 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Sun, 24 Oct 2010 14:20:02 +0000 Subject: * Don't create thunks for variable lookups (if possible). This significantly reduces the number of values allocated (e.g. from 8.7m to 4.9m for the Bittorrent test). --- src/libexpr/primops.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/libexpr/primops.cc') diff --git a/src/libexpr/primops.cc b/src/libexpr/primops.cc index 20b8395088d7..3e32dd3ffc0e 100644 --- a/src/libexpr/primops.cc +++ b/src/libexpr/primops.cc @@ -1070,7 +1070,7 @@ void EvalState::createBaseEnv() /* Add a wrapper around the derivation primop that computes the `drvPath' and `outPath' attributes lazily. */ string s = "attrs: let res = derivationStrict attrs; in attrs // { drvPath = res.drvPath; outPath = res.outPath; type = \"derivation\"; }"; - mkThunk(v, baseEnv, parseExprFromString(*this, s, "/")); + mkThunk_(v, parseExprFromString(*this, s, "/")); addConstant("derivation", v); // Paths -- cgit 1.4.1