Clean up generated operator<<(os, enum).

Pass enums by value instead of const reference.

Do not generate operator<< sources for headers that have no
enums or no declarations of operator<<. Do not define the
operator<< for flag enums; these were unused anyway.

Add generated operator<< for some enums in nodes.h . Change
the operator<< for ComparisonBias so that the graph
visualizer can use it but do not use the generated
operator<< yet as that would require changing checker tests.

Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Change-Id: Ifd4c455c2fa921a9668c966a13068d43b9c6e173
diff --git a/tools/generate_operator_out.py b/tools/generate_operator_out.py
index 921ae68..91e1caf 100755
--- a/tools/generate_operator_out.py
+++ b/tools/generate_operator_out.py
@@ -206,7 +206,7 @@
             print('namespace %s {' % namespace)
 
         print(
-            'std::ostream& operator<<(std::ostream& os, const %s& rhs) {' % enum_name)
+            'std::ostream& operator<<(std::ostream& os, %s rhs) {' % enum_name)
         print('  switch (rhs) {')
         for (enum_value, enum_text) in _ENUMS[enum_name]:
             print('    case %s: os << "%s"; break;' % (enum_value, enum_text))