]> granicus.if.org Git - clang/commit
Do an initial hack at replacing one of the incredibly inefficient
authorChris Lattner <sabre@nondot.org>
Sat, 12 Apr 2008 20:28:24 +0000 (20:28 +0000)
committerChris Lattner <sabre@nondot.org>
Sat, 12 Apr 2008 20:28:24 +0000 (20:28 +0000)
commit5c9dc5ac75de8d620311cdc20223998e0293d61f
treeb2e629b2cd3831f46532d75daa02dd0254781faa
parent72e62b0c6049b7e76b508bb74116314eb7772be5
Do an initial hack at replacing one of the incredibly inefficient
(but simple!) datastructures in the rewriter with a more complex but
more efficient one.

This replaces the Deltas vector with a specialized BTree that makes
delta lookups much more efficient.  This speeds up -emit-html on a 500K
.i file from 157.154 to 27.127 seconds on my machine (5.8x).

While this code is functional, it isn't very pretty, I have much
refactoring planned for it, and will remove the USE_VECTOR ifdef.
Stay tuned.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@49586 91177308-0d34-0410-b5e6-96231b3b80d8
clang.xcodeproj/project.pbxproj
include/clang/Rewrite/DeltaTree.h [new file with mode: 0644]
include/clang/Rewrite/Rewriter.h
lib/Rewrite/Rewriter.cpp