I don't pretend this is the most efficient or pretty, but here's a go at what I think you're after (see latter part of post for faster and simpler realizations):
a = {1, 1, 2, 1, 1, 3};
b = {1, 5, 5, 1};
result = Join[
Flatten[ConstantArray @@@
Flatten[Replace[Cases[GatherBy[Join[Tally[#1], Tally[#2]], First],
{{Alternatives @@ a, _} ..}], {{a_, b_}, {c_, d_}} :>
{{a, Max[0, b - d]}}, 1], 1]],
Flatten[
ConstantArray @@@
Flatten[Replace[Cases[GatherBy[Join[Tally[#2], Tally[#1]], First],
{{Alternatives @@ b, _} ..}], {{a_, b_}, {c_, d_}} :>
{{a, Max[0, b - d]}}, 1], 1]]] &[a, b]
(* {1, 1, 2, 3, 5, 5} *)
Here's a much faster alternative for big lists:
Module[{ta = Tally[#1], tb = Tally[#2], tab, tba, j},
tab = Tally[Join[#1, #2]][[;; Length@ta]];
ta[[All, 2]] = ta[[All, 2]] - (tab - ta)[[All, 2]];
tba = Tally[Join[#2, #1]][[;; Length@tb]];
tb[[All, 2]] = tb[[All, 2]] - (tba - tb)[[All, 2]];
j = Join[ta, tb];
Flatten[ConstantArray @@@ Pick[j, Sign[j[[All, 2]]], 1]]] &[a, b]
And after partitioning a steak and doing a gatherby on dessert, this simpler and even faster idea popped into the cranium:
With[{du = DeleteDuplicates@Join[#1, #2]},
Join @@ ConstantArray @@@
Transpose[{du, Abs[Subtract[Tally[Join[du, #1]], Tally[Join[du, #2]]][[All, 2]]]}]] &[a, b]
Join @@ ConstantArray @@@ Flatten[{Tally /@ {a, b} //. {{a___, {n_, x_}, b___}, {c___, {n_, y_}, d___}} :> {{a, b}, {c, d, {n,Abs[ x - y]}}}, 1]– Dr. belisarius Jun 04 '14 at 01:07BlankNullSequence... the performance killer. – ciao Jun 04 '14 at 01:13___always tend to indulge a nap – Dr. belisarius Jun 04 '14 at 01:15