diff --git a/mercurial/cmdutil.py b/mercurial/cmdutil.py
index 90ca344a7c550f062843dad4afa662dc873fba9c_bWVyY3VyaWFsL2NtZHV0aWwucHk=..9224cc2e99ccc19458ae873aaed7ba55fed1b1e7_bWVyY3VyaWFsL2NtZHV0aWwucHk= 100644
--- a/mercurial/cmdutil.py
+++ b/mercurial/cmdutil.py
@@ -1296,9 +1296,6 @@
 
     wlock = repo.wlock()
     try:
-        # Fix up dirstate for copies and renames
-        duplicatecopies(repo, None, base.node())
-
         # First, do a regular commit to record all changes in the working
         # directory (if there are any)
         node = commit(ui, repo, commitfunc, pats, opts)
@@ -1326,6 +1323,8 @@
             date = ctx.date()
             message = ctx.description()
             extra = ctx.extra()
+            # Recompute copies (avoid recording a -> b -> a)
+            copied = copies.pathcopies(base, ctx)
 
             # Prune files which were reverted by the updates: if old introduced
             # file X and our intermediate commit, node, renamed that file, then
@@ -1339,8 +1338,7 @@
                     if f in base.manifest():
                         b = base.filectx(f)
                         return (a.data() == b.data()
-                                and a.flags() == b.flags()
-                                and a.renamed() == b.renamed())
+                                and a.flags() == b.flags())
                     else:
                         return False
                 else:
@@ -1349,7 +1347,13 @@
 
             def filectxfn(repo, ctx_, path):
                 try:
-                    return ctx.filectx(path)
+                    fctx = ctx[path]
+                    flags = fctx.flags()
+                    mctx = context.memfilectx(fctx.path(), fctx.data(),
+                                              islink='l' in flags,
+                                              isexec='x' in flags,
+                                              copied=copied.get(path))
+                    return mctx
                 except KeyError:
                     raise IOError()
         else:
diff --git a/tests/test-commit-amend.t b/tests/test-commit-amend.t
index 90ca344a7c550f062843dad4afa662dc873fba9c_dGVzdHMvdGVzdC1jb21taXQtYW1lbmQudA==..9224cc2e99ccc19458ae873aaed7ba55fed1b1e7_dGVzdHMvdGVzdC1jb21taXQtYW1lbmQudA== 100644
--- a/tests/test-commit-amend.t
+++ b/tests/test-commit-amend.t
@@ -293,5 +293,5 @@
   $ hg cp a f
   $ mv f.orig f
   $ hg ci --amend -m replacef
-  saved backup bundle to $TESTTMP/.hg/strip-backup/0ce2c92dc50d-amend-backup.hg
+  saved backup bundle to $TESTTMP/.hg/strip-backup/20a7413547f9-amend-backup.hg
   $ hg st --change . --copies
@@ -297,3 +297,2 @@
   $ hg st --change . --copies
-  M f
   $ hg log -r . --template "{file_copies}\n"
@@ -299,5 +298,18 @@
   $ hg log -r . --template "{file_copies}\n"
-  f (a)
+  
+
+Move added file (issue3410):
+
+  $ echo g >> g
+  $ hg ci -Am g
+  adding g
+  $ hg mv g h
+  $ hg ci --amend
+  saved backup bundle to $TESTTMP/.hg/strip-backup/5daa77a5d616-amend-backup.hg
+  $ hg st --change . --copies h
+  A h
+  $ hg log -r . --template "{file_copies}\n"
+  
 
 Can't rollback an amend: