Files
swift-mirror/utils/test-prefix-map/Makefile
John McCall cc7938ad21 Implement a trie data structure. Specifically, implement
a ternary tree with a fixed-length per-node inline key buffer.

I plan to use this for metadata path caches, where it's useful to
be able to quickly find the most-derived point along a path that
you've already cached, but it should be useful for other things
in the compiler as well, like function-with-argument-label
lookups and possibly code completion.

This is quite a bit more space-efficient (and somewhat faster)
than doing scans after a lower_bound on a std::map<std::string, T>.

I haven't implemented balancing yet, and I don't need delete at
all for metadata paths, so I don't plan to work on that.

Swift SVN r32453
2015-10-06 01:14:30 +00:00

21 lines
540 B
Makefile

srcroot = /Volumes/Data/swift
objroot = /Volumes/Data/swift-DA
CXXFLAGS = -std=c++11 \
-stdlib=libc++ \
-g \
-I$(srcroot)/tools/swift/include \
-I$(srcroot)/tools/clang/include \
-I$(srcroot)/include \
-I$(objroot)/include \
-I$(objroot)/tools/clang/include \
-D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS
LDFLAGS = -L$(objroot)/lib -lswiftBasic -lLLVMSupport -lcurses
main: main.cpp $(srcroot)/tools/swift/include/swift/Basic/PrefixMap.h
$(CXX) $(CXXFLAGS) $(LDFLAGS) -o main main.cpp
clean:
rm main