Randomized Brainfuck Compiler Joe is your average BF developer. He is about to check in his code changes to their repository when he gets a call from his boss. "Joe! The new client's machine is broken! The brainfuck interpreter sets all the cells to random values before program execution. No time to fix it, your code will have to deal with it." Joe doesn't think much of it, and is about to write a program to set the first million cells to zero, when his boss interrupts him again - "... and don't think about using brute force, the code has to be as small as possible." Now you have to help poor Joe!

Specifications


You will get some valid brainfuck code as input
Your program will then modify the code so that it should work on a randomized brainfuck interpreter
This means that before program execution, the cells can be set to any value.
The new program should have the exact same behavior no matter the initial conditions.
The interpreter will have max-cell value of 255 with wrapping, and an infinite length tape.


Scoring

Your score is 10 times the compiler size in bytes plus the sum of the test case sizes. Lowest score obviously wins.To mitigate against test-case optimization, I reserve the right to change the test-cases around if I suspect anything, and probably will do so before picking a winner.

Test Cases

(I got these from the esolangs page and this webpage: http://www.hevanet.com/cristofd/brainfuck/). Also thanks to @Sparr for the last test case.


Hello World: ++++++++[&gt;++++[&gt;++&gt;+++&gt;+++&gt;+&lt;&lt;&lt;&lt;-]&gt;+&gt;+&gt;-&gt;&gt;+[&lt;]&lt;-]&gt;&gt;.&gt;---.+++++++..+++.&gt;&gt;.&lt;-.&lt;.+++.------.--------.&gt;&gt;+.&gt;++.
Reverse Input: &gt;,[&gt;,]&lt;[.&lt;]
Powers of Two (Infinite Stream): &gt;++++++++++&gt;&gt;+&lt;+[[+++++[&gt;++++++++&lt;-]&gt;.&lt;++++++[&gt;--------&lt;-]+&lt;&lt;]&gt;.&gt;[-&gt;[
&lt;++&gt;-[&lt;++&gt;-[&lt;++&gt;-[&lt;++&gt;-[&lt;--------&gt;&gt;[-]++&lt;-[&lt;++&gt;-]]]]]]&lt;[&gt;+&lt;-]+&gt;&gt;]&lt;&lt;]
Squares Under 10000: ++++[&gt;+++++&lt;-]&gt;[&lt;+++++&gt;-]+&lt;+[&gt;[&gt;+&gt;+&lt;&lt;-]++&gt;&gt;[&lt;&lt;+&gt;&gt;-]&gt;&gt;&gt;[-]++&gt;[-]+&gt;&gt;&gt;+[[-]++++++&gt;&gt;&gt;]&lt;&lt;&lt;[[&lt;++++++++&lt;++&gt;&gt;-]+&lt;.&lt;[&gt;----&lt;-]&lt;]&lt;&lt;[&gt;&gt;&gt;&gt;&gt;[&gt;&gt;&gt;[-]+++++++++&lt;[&gt;-&lt;-]+++++++++&gt;[-[&lt;-&gt;-]+[&lt;&lt;&lt;]]&lt;[&gt;+&lt;-]&gt;]&lt;&lt;-]&lt;&lt;-]
Fibonacci Stream: &gt;++++++++++&gt;+&gt;+[[+++++[&gt;++++++++&lt;-]&gt;.&lt;++++++[&gt;--------&lt;-]+&lt;&lt;&lt;]&gt;.&gt;&gt;[[-]&lt;[&gt;+&lt;-]&gt;&gt;[&lt;&lt;+&gt;+&gt;-]&lt;[&gt;+&lt;-[&gt;+&lt;-[&gt;+&lt;-[&gt;+&lt;-[&gt;+&lt;-[&gt;+&lt;-[&gt;+&lt;-[&gt;+&lt;-[&gt;+&lt;-[&gt;[-]&gt;+&gt;+&lt;&lt;&lt;-[&gt;+&lt;-]]]]]]]]]]]+&gt;&gt;&gt;]&lt;&lt;&lt;]
ASCII Sequence till input: ,[.[&gt;+&lt;-]&gt;-] (This one requires varying cell numbers based on the input)
sed, 46 byte compiler
s/&lt;/&lt;&lt;/g
s/&gt;/&gt;[-&gt;[-]&gt;[-]+&lt;&lt;]&gt;/g
s/^/[-]&gt;[-]+&lt;/

I didn't notice that the output was also supposed to be golf until after writing the program, so I will go for the short compiler. Also it was far too much work to test, so please notify if it does not function correctly :)