HomePhorge

Tweak to fix for #4302--dangling ref to known_resource_types
1d494a3104e9Unpublished

Unpublished Commit ยท Learn More

Repository Importing: This repository is still importing.

Description

Tweak to fix for #4302--dangling ref to known_resource_types

Since we were clearing the thread variable containing the compiler's reference
to it's environment's known resource types at the start of each compile the
reference remaining at the end of a compilation could never be used and was
thus just garbage that we were arbitrarily retaining.

This patch moves the clearing of the thread var to the _end_ of compilation so
that it's always nil except in the middle of a compile.

This raises an interesting question; should the ref just live on the compiler
object and we could dispense with the thread-var? It might require things that
now only know about the environment to need a ref to the compiler and introduce
other thread issues (e.g. we might just end up needing a :current_compiler
thread variable, for no net gain in simplicity).

Details

Provenance
Markus Roberts <Markus@reality.com>Authored on
vanmeeuwenPushed on Jun 2 2015, 2:22 PM
Parents
rPU23830504dfeb: Fix #4302 - Compilation speed regression compared to 2.6
Branches
Unknown
Tags
Unknown

Event Timeline

Markus Roberts <Markus@reality.com> committed rPU1d494a3104e9: Tweak to fix for #4302--dangling ref to known_resource_types (authored by Markus Roberts <Markus@reality.com>).Jul 26 2010, 7:24 AM