Commit Graph

25 Commits

Author SHA1 Message Date
Dan Gohman 2c6a821fd7 Move the space in overview output for commands out of each of the
commands and into the common code.

llvm-svn: 42752
2007-10-08 15:45:12 +00:00
Gabor Greif 0e535c3c8e Pretty straightforward replacement of "bytecode" by "bitcode"
performed on tools/ first, in order not to cause lethal damage

llvm-svn: 37877
2007-07-04 21:55:50 +00:00
Chris Lattner 6d80e21a1d switch tools to bitcode instead of bytecode
llvm-svn: 36868
2007-05-06 09:29:57 +00:00
Chris Lattner 19f599471c add inline asm code
llvm-svn: 36826
2007-05-06 01:50:11 +00:00
Chris Lattner f25f710c4d add a denser encoding for null terminated strings, add a 6-bit abbrev as
well.  This shrinks kc++ from 2724088 to 2717360 bytes.

llvm-svn: 36821
2007-05-06 00:53:07 +00:00
Chris Lattner 4a7ac9fd70 emit spiffy little histograms of codes, if enabled. Don't print averages if
there is only one item.

llvm-svn: 36773
2007-05-05 01:46:49 +00:00
Chris Lattner 9e808cd330 do not charge subblock sizes to the parent block.
llvm-svn: 36772
2007-05-05 01:29:31 +00:00
Chris Lattner 9181ddf91d update to new APIs, make output a bit (haha) nicer
llvm-svn: 36768
2007-05-05 00:17:42 +00:00
Chris Lattner 0b7c5121f7 add support for new codes/block
llvm-svn: 36726
2007-05-04 03:01:41 +00:00
Chris Lattner 5fab65dbbf add phi
llvm-svn: 36611
2007-05-01 02:43:46 +00:00
Chris Lattner 3543caacd3 Implement much expanded dumper support. We now print stuff like:
<MODULE_BLOCK NumWords=27 BlockCodeSize=3>
  <TYPE_BLOCK NumWords=7 BlockCodeSize=4>
    <NUMENTRY op0=7>
    <POINTER op0=1>
    <FUNCTION op0=0 op1=2 op2=2 op3=2 op4=2>
    <VECTOR op0=2 op1=3>
    <INTEGER op0=64>
    <VECTOR op0=8 op1=5>
    <INTEGER op0=16>
    <VOID>
...

With work, the operands can be pretty printed symbolically.

llvm-svn: 36579
2007-04-29 21:48:19 +00:00
Chris Lattner 1684cee5a2 add some simple per-block statistics
llvm-svn: 36576
2007-04-29 20:00:02 +00:00
Chris Lattner ca0ea543f5 Implement support to read an arbitrary bitcode file. Next up, dumping the
file symbolically and actually computing statistics.

llvm-svn: 36557
2007-04-29 08:31:14 +00:00
Chris Lattner 0399758b5f very early support for analyzing a bitstream. This opens the file, starts
reading the stream, and detects whether it is LLVM IR or not.

llvm-svn: 36556
2007-04-29 08:12:22 +00:00
Chris Lattner cc18989c14 fit in 80 cols
llvm-svn: 36551
2007-04-29 05:51:00 +00:00
Chris Lattner a0e49f2ead push bytecode decompressor out through APIs. Now the bytecode reader
api's look like this:

ModuleProvider *getBytecodeModuleProvider(
  const std::string &Filename,  ///< Name of file to be read
  BCDecompressor_t *BCDC = Compressor::decompressToNewBuffer,
  std::string* ErrMsg = 0,      ///< Optional error message holder
  BytecodeHandler* H = 0        ///< Optional handler for reader events
);

This is ugly, but allows a client to say:

  getBytecodeModuleProvider("foo", 0);

If they do this, there is no dependency on the compression libraries, saving
codesize.

llvm-svn: 34012
2007-02-07 21:41:02 +00:00
Chris Lattner 76d4632d92 make all llvm tools call llvm_shutdown when they exit, static'ify some stuff.
With this change, I can now move -stats to print when llvm_shutdown is called.

llvm-svn: 32250
2006-12-06 01:18:01 +00:00
Reid Spencer de46e48420 For PR786:
Turn on -Wunused and -Wno-unused-parameter. Clean up most of the resulting
fall out by removing unused variables. Remaining warnings have to do with
unused functions (I didn't want to delete code without review) and unused
variables in generated code. Maintainers should clean up the remaining
issues when they see them. All changes pass DejaGnu tests and Olden.

llvm-svn: 31380
2006-11-02 20:25:50 +00:00
Chris Lattner 5734e8d7c3 Change the verifier to never throw an exception. Instead verifyModule canoptionally return the string error, which is an easier api for clients touse anyway.
llvm-svn: 29017
2006-07-06 18:02:27 +00:00
Misha Brukman 650ba8eb56 Remove trailing whitespace
llvm-svn: 21428
2005-04-22 00:00:37 +00:00
Reid Spencer 996ec72d48 For PR351:
* Place a try/catch block around the entire tool to Make sure std::string
  exceptions are caught and printed before exiting the tool.
* Make sure we catch unhandled exceptions at the top level so that we don't
  abort with a useless message but indicate than an unhandled exception was
  generated.

llvm-svn: 19192
2004-12-30 05:36:08 +00:00
Reid Spencer 7c16caa336 Changes For Bug 352
Move include/Config and include/Support into include/llvm/Config,
include/llvm/ADT and include/llvm/Support. From here on out, all LLVM
public header files must be under include/llvm/.

llvm-svn: 16137
2004-09-01 22:55:40 +00:00
Reid Spencer e3263ecaf0 The functions in Signal.h are now in the llvm::sys namespace - adjust
llvm-svn: 16091
2004-08-29 19:28:55 +00:00
Reid Spencer d6dd465326 Correct to change interface of the analyzer.
llvm-svn: 15986
2004-08-21 21:00:24 +00:00
Reid Spencer 5780de6219 Name Change: llvm-abcd -> llvm-bcanalyzer
llvm-svn: 14555
2004-07-02 03:22:53 +00:00