diff --git a/com.oracle.truffle.r.runtime/src/com/oracle/truffle/r/runtime/env/frame/FrameSlotChangeMonitor.java b/com.oracle.truffle.r.runtime/src/com/oracle/truffle/r/runtime/env/frame/FrameSlotChangeMonitor.java
index c616637b9d65a548a3bbbaa1c7305a4c1e277e08..8455c58c0cfc800c59c6c75c67e4db142cee5a14 100644
--- a/com.oracle.truffle.r.runtime/src/com/oracle/truffle/r/runtime/env/frame/FrameSlotChangeMonitor.java
+++ b/com.oracle.truffle.r.runtime/src/com/oracle/truffle/r/runtime/env/frame/FrameSlotChangeMonitor.java
@@ -391,9 +391,11 @@ public final class FrameSlotChangeMonitor {
             }
         }
         target.lookupResults.clear();
-        target.previousLookups.clear();
-        for (FrameDescriptor sub : target.subDescriptors) {
-            invalidateAllNames(getMetaData(sub));
+        if (!target.previousLookups.isEmpty()) {
+            target.previousLookups.clear();
+            for (FrameDescriptor sub : target.subDescriptors) {
+                invalidateAllNames(getMetaData(sub));
+            }
         }
     }