diff options
author | Douglas Gregor <dgregor@apple.com> | 2009-01-26 22:44:13 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2009-01-26 22:44:13 +0000 |
commit | f829825d04b3029a62b470058a12d1186c6eefea (patch) | |
tree | 83ab7ae8ca74ab6136231900654a916cce6d4edd /llvm/lib/CodeGen/MachineFunction.cpp | |
parent | 9240b3eccb9c2500f596fb491fd848d9c83e1423 (diff) | |
download | llvm-f829825d04b3029a62b470058a12d1186c6eefea.zip llvm-f829825d04b3029a62b470058a12d1186c6eefea.tar.gz llvm-f829825d04b3029a62b470058a12d1186c6eefea.tar.bz2 |
Some micro-optimizations for DISABLE_SMART_POINTERS:
- When it's safe, ActionResult uses the low bit of the pointer for
the "invalid" flag rather than a separate "bool" value. This keeps
GCC from generating some truly awful code, for a > 3x speedup in the
result-passing microbenchmark.
- When DISABLE_SMART_POINTERS is defined, store an ActionResult
within ASTOwningResult rather than an ASTOwningPtr. Brings the
performance benefits of the above to smart pointers with
DISABLE_SMART_POINTERS defined.
Sadly, these micro-benchmark performance improvements don't seem to
make much of a difference on Cocoa.h right now. However, they're
harmless and might help with future optimizations.
llvm-svn: 63061
Diffstat (limited to 'llvm/lib/CodeGen/MachineFunction.cpp')
0 files changed, 0 insertions, 0 deletions