<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - Tidy up llvm-size's error messages"
href="https://bugs.llvm.org/show_bug.cgi?id=42970">42970</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Tidy up llvm-size's error messages
</td>
</tr>
<tr>
<th>Product</th>
<td>tools
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Windows NT
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>llvm-objcopy/strip
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>jh7370.2008@my.bristol.ac.uk
</td>
</tr>
<tr>
<th>CC</th>
<td>alexander.v.shaposhnikov@gmail.com, jake.h.ehrlich@gmail.com, jh7370.2008@my.bristol.ac.uk, llvm-bugs@lists.llvm.org, rupprecht@google.com
</td>
</tr></table>
<p>
<div>
<pre>A number of llvm-size's error messages leave a bit to be desired. For example,
if you feed it an unrecognized binary, you get:
c:\llvm\build\debug\bin\llvm-size.exe:
C:\llvm\llvm\test\tools\llvm-size\invalid-input.test The file was not
recognized as a valid object file
If the input file does not exist:
C:\llvm\build\Debug\bin\llvm-size.exe: blah.a no such file or directory
Note that in both these cases, the file name is neither quoted nor separated
from the error message body in any way, which makes the error message hard to
read:
C:\llvm\build\Debug\bin\llvm-size.exe: this file does not exist no such file or
directory
On a related note, llvm-size has a small block of code that looks to be
reporting an error message for an unrecognized file:
errs() << ToolName << ": " << file << ": "
<< "Unrecognized file type.\n";
However, in the first example above, it does not match the error message that
comes out for this case. Probably better would be to say "unsupported file
type" (an unrecognised one is one that the createBinary method doesn't know
about, whilst an unsupported one is one it does know about, but llvm-size
doesn't understand, e.g. minidumps).</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>