Index: llvm/trunk/utils/opt-viewer/opt-viewer.py =================================================================== --- llvm/trunk/utils/opt-viewer/opt-viewer.py +++ llvm/trunk/utils/opt-viewer/opt-viewer.py @@ -183,7 +183,7 @@ '''.format(filename), file=self.stream) - self.html_formatter = HtmlFormatter() + self.html_formatter = HtmlFormatter(encoding='utf-8') self.cpp_lexer = CppLexer() def render_source_line(self, linenum, line):