Index: trunk/src/org/openstreetmap/josm/gui/dialogs/properties/RecentTagCollection.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/dialogs/properties/RecentTagCollection.java	(revision 16079)
+++ trunk/src/org/openstreetmap/josm/gui/dialogs/properties/RecentTagCollection.java	(revision 16080)
@@ -4,5 +4,4 @@
 import java.util.ArrayList;
 import java.util.Iterator;
-import java.util.LinkedHashMap;
 import java.util.List;
 import java.util.Map;
@@ -13,4 +12,5 @@
 import org.openstreetmap.josm.data.osm.search.SearchSetting;
 import org.openstreetmap.josm.data.preferences.ListProperty;
+import org.openstreetmap.josm.gui.util.LruCache;
 import org.openstreetmap.josm.tools.Logging;
 
@@ -19,22 +19,4 @@
  */
 class RecentTagCollection {
-
-    /**
-     * LRU cache for recently added tags (http://java-planet.blogspot.com/2005/08/how-to-set-up-simple-lru-cache-using.html)
-     */
-    static final class LruCache extends LinkedHashMap<Tag, Void> {
-        private static final long serialVersionUID = 1L;
-        private final int capacity;
-
-        LruCache(int capacity) {
-            super(capacity + 1, 1.1f, true);
-            this.capacity = capacity;
-        }
-
-        @Override
-        protected boolean removeEldestEntry(Map.Entry<Tag, Void> eldest) {
-            return size() > capacity;
-        }
-    }
 
     private final Map<Tag, Void> recentTags;
Index: trunk/src/org/openstreetmap/josm/gui/layer/OsmDataLayer.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/layer/OsmDataLayer.java	(revision 16079)
+++ trunk/src/org/openstreetmap/josm/gui/layer/OsmDataLayer.java	(revision 16080)
@@ -29,5 +29,4 @@
 import java.util.HashMap;
 import java.util.HashSet;
-import java.util.LinkedHashMap;
 import java.util.List;
 import java.util.Map;
@@ -119,4 +118,5 @@
 import org.openstreetmap.josm.gui.progress.swing.PleaseWaitProgressMonitor;
 import org.openstreetmap.josm.gui.util.GuiHelper;
+import org.openstreetmap.josm.gui.util.LruCache;
 import org.openstreetmap.josm.gui.widgets.FileChooserManager;
 import org.openstreetmap.josm.gui.widgets.JosmTextArea;
@@ -182,5 +182,5 @@
 
     /** List of recent relations */
-    private final Map<Relation, Void> recentRelations = new LruCache(PROPERTY_RECENT_RELATIONS_NUMBER.get()+1);
+    private final Map<Relation, Void> recentRelations = new LruCache<>(PROPERTY_RECENT_RELATIONS_NUMBER.get());
 
     /**
@@ -257,16 +257,4 @@
     static String createLayerName(Object arg) {
         return tr("Data Layer {0}", arg);
-    }
-
-    static final class LruCache extends LinkedHashMap<Relation, Void> {
-        private static final long serialVersionUID = 1L;
-        LruCache(int initialCapacity) {
-            super(initialCapacity, 1.1f, true);
-        }
-
-        @Override
-        protected boolean removeEldestEntry(Map.Entry<Relation, Void> eldest) {
-            return size() > PROPERTY_RECENT_RELATIONS_NUMBER.get();
-        }
     }
 
Index: trunk/src/org/openstreetmap/josm/gui/tagging/presets/TaggingPresetItem.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/tagging/presets/TaggingPresetItem.java	(revision 16079)
+++ trunk/src/org/openstreetmap/josm/gui/tagging/presets/TaggingPresetItem.java	(revision 16080)
@@ -9,5 +9,4 @@
 import java.util.Collection;
 import java.util.EnumSet;
-import java.util.LinkedHashMap;
 import java.util.List;
 import java.util.Map;
@@ -24,4 +23,5 @@
 import org.openstreetmap.josm.gui.tagging.ac.AutoCompletionList;
 import org.openstreetmap.josm.gui.tagging.ac.AutoCompletionManager;
+import org.openstreetmap.josm.gui.util.LruCache;
 import org.openstreetmap.josm.spi.preferences.Config;
 import org.openstreetmap.josm.tools.ImageProvider;
@@ -35,6 +35,6 @@
 public abstract class TaggingPresetItem {
 
-    // cache the parsing of types using a LRU cache (http://java-planet.blogspot.com/2005/08/how-to-set-up-simple-lru-cache-using.html)
-    private static final Map<String, Set<TaggingPresetType>> TYPE_CACHE = new LinkedHashMap<>(16, 1.1f, true);
+    // cache the parsing of types using a LRU cache
+    private static final Map<String, Set<TaggingPresetType>> TYPE_CACHE = new LruCache<>(16);;
 
     protected void initAutoCompletionField(AutoCompletingTextField field, String... key) {
Index: trunk/src/org/openstreetmap/josm/gui/util/LruCache.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/util/LruCache.java	(revision 16080)
+++ trunk/src/org/openstreetmap/josm/gui/util/LruCache.java	(revision 16080)
@@ -0,0 +1,24 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.gui.util;
+
+import java.util.LinkedHashMap;
+import java.util.Map;
+
+/**
+ * LRU cache
+ * @apiNote http://java-planet.blogspot.com/2005/08/how-to-set-up-simple-lru-cache-using.html
+ */
+public final class LruCache<K, V> extends LinkedHashMap<K, V> {
+    private static final long serialVersionUID = 1L;
+    private final int capacity;
+
+    public LruCache(int capacity) {
+        super(capacity + 1, 1.1f, true);
+        this.capacity = capacity;
+    }
+
+    @Override
+    protected boolean removeEldestEntry(Map.Entry<K, V> eldest) {
+        return size() > capacity;
+    }
+}
Index: trunk/src/org/openstreetmap/josm/io/AbstractReader.java
===================================================================
--- trunk/src/org/openstreetmap/josm/io/AbstractReader.java	(revision 16079)
+++ trunk/src/org/openstreetmap/josm/io/AbstractReader.java	(revision 16080)
@@ -42,4 +42,5 @@
 import org.openstreetmap.josm.gui.progress.NullProgressMonitor;
 import org.openstreetmap.josm.gui.progress.ProgressMonitor;
+import org.openstreetmap.josm.gui.util.LruCache;
 import org.openstreetmap.josm.tools.CheckParameterUtil;
 import org.openstreetmap.josm.tools.Logging;
@@ -421,7 +422,10 @@
     }
 
+    private final Map<String, Integer> timestampCache = new LruCache<>(30);
+
     protected final void parseTimestamp(PrimitiveData current, String time) {
         if (time != null && !time.isEmpty()) {
-            current.setRawTimestamp((int) (DateUtils.tsFromString(time)/1000));
+            int timestamp = timestampCache.computeIfAbsent(time, t -> (int) (DateUtils.tsFromString(t) / 1000));
+            current.setRawTimestamp(timestamp);
         }
     }
