Revert "Remove separate compilerdebug.h in favor of debug.h"

Causing compile warnings in Release:

1>compiler\translator\CallDAG.cpp(238): error C2220: warning treated as error - no 'object' file generated
1>compiler\translator\CallDAG.cpp(238): warning C4189: 'op' : local variable is initialized but not referenced
1>compiler\translator\IntermNode.cpp(1495): error C2220: warning treated as error - no 'object' file generated
1>compiler\translator\IntermNode.cpp(1495): warning C4189: 'replaced' : local variable is initialized but not referenced
1>compiler\translator\IntermNode.cpp(1517): warning C4189: 'replaced' : local variable is initialized but not referenced

This reverts commit 5271025865b34685da71d0309131c5aff2e32f71.

Change-Id: Icdf1c37eef22a13d083767609ab0b0285d3dc517
Reviewed-on: https://chromium-review.googlesource.com/267359
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Tested-by: Jamie Madill <jmadill@chromium.org>
diff --git a/src/compiler/translator/compilerdebug.cpp b/src/compiler/translator/compilerdebug.cpp
new file mode 100644
index 0000000..10cbe43
--- /dev/null
+++ b/src/compiler/translator/compilerdebug.cpp
@@ -0,0 +1,37 @@
+//
+// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// debug.cpp: Debugging utilities.
+
+#include "compiler/translator/compilerdebug.h"
+
+#include <stdarg.h>
+#include <stdio.h>
+
+#include "compiler/translator/InitializeParseContext.h"
+#include "compiler/translator/ParseContext.h"
+
+#ifdef TRACE_ENABLED
+static const int kTraceBufferLen = 1024;
+
+extern "C" {
+void Trace(const char *format, ...) {
+    if (!format) return;
+
+    TParseContext* parseContext = GetGlobalParseContext();
+    if (parseContext) {
+        char buf[kTraceBufferLen];
+        va_list args;
+        va_start(args, format);
+        vsnprintf(buf, kTraceBufferLen, format, args);
+        va_end(args);
+
+        parseContext->trace(buf);
+    }
+}
+}  // extern "C"
+#endif  // TRACE_ENABLED
+