SVG Memory Leak

Won’t fix Issue #212462


May 14, 2014
This issue is public.
Reported by 0 people

Sign in to watch or report this issue.

Steps to reproduce


Repro Steps:

Save this as HTML and open in IE, see memory usage in Taskmanager:

<!DOCTYPE html>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<script type="text/javascript">
var count = 1000;
var svg = document.createElementNS("", “svg”);
svg.setAttribute('width’, ‘800’);
svg.setAttribute('height’, ‘800’);

function update() {
// remove existing circles
var circles = svg.querySelectorAll(“circle”)
for (var i = circles.length - 1; i >= 0; i–) {
var parent = circles[i].parentNode;
if (parent) parent.removeChild(circles[i]);

// add new ones. Yes, would make more sense to update the x,y on the existing
// circles but this is to show what happens in IE with lots of nodes being added/removed
for (var j = count - 1; j >= 0; j–) {
var node = document.createElementNS("", ‘circle’); = ‘id’ + Math.random();
node.setAttributeNS(null, "cx", Math.random()800);
node.setAttributeNS(null, "cy", Math.random()
node.setAttributeNS(null, "r", 5);
node.setAttributeNS(null, "fill", “blue”);

setInterval(update, 1000);


Expected Results:

The memory should not be growing up.

Actual Results:


0 attachments

    Comments and activity

    • Microsoft Edge Team

      Changed Assigned To to “Kamen M.”

      Changed Assigned To from “Kamen M.” to “Kevin B.”

      Changed Status to “Confirmed”

      Changed Status from “Confirmed” to “Won’t fix”

      Changed Status from “Won’t fix” to “Fixed”

      Changed Status from “Fixed” to “Won’t fix”

    You need to sign in to your Microsoft account to add a comment.

    Sign in